added a first port of musredit form Qt 4.x to Qt 5.x
5
src/musredit_qt5/Makefile.am
Normal file
@ -0,0 +1,5 @@
|
||||
## Process this file with automake to create Makefile.in
|
||||
|
||||
CLEANFILES = *~ core
|
||||
|
||||
|
967
src/musredit_qt5/PAdmin.cpp
Normal file
@ -0,0 +1,967 @@
|
||||
/****************************************************************************
|
||||
|
||||
PAdmin.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <cstdlib>
|
||||
#include <iostream>
|
||||
using namespace std;
|
||||
|
||||
#include <QMessageBox>
|
||||
#include <QString>
|
||||
#include <QFile>
|
||||
#include <QTextStream>
|
||||
#include <QVector>
|
||||
|
||||
#include "PAdmin.h"
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// implementation of PAdminXMLParser class
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>XML Parser class for the musredit administration file.
|
||||
*
|
||||
* \param admin pointer to an admin class instance.
|
||||
*/
|
||||
PAdminXMLParser::PAdminXMLParser(PAdmin *admin) : fAdmin(admin)
|
||||
{
|
||||
fKeyWord = eEmpty;
|
||||
fFunc = false;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Routine called at the beginning of the XML parsing process.
|
||||
*/
|
||||
bool PAdminXMLParser::startDocument()
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Routine called when a new XML tag is found. Here it is used
|
||||
* to set a tag for filtering afterwards the content.
|
||||
*
|
||||
* \param qName name of the XML tag.
|
||||
*/
|
||||
bool PAdminXMLParser::startElement( const QString&, const QString&,
|
||||
const QString& qName,
|
||||
const QXmlAttributes& )
|
||||
{
|
||||
if (qName == "timeout") {
|
||||
fKeyWord = eTimeout;
|
||||
} else if (qName == "font_name") {
|
||||
fKeyWord = eFontName;
|
||||
} else if (qName == "font_size") {
|
||||
fKeyWord = eFontSize;
|
||||
} else if (qName == "exec_path") {
|
||||
fKeyWord = eExecPath;
|
||||
} else if (qName == "default_save_path") {
|
||||
fKeyWord = eDefaultSavePath;
|
||||
} else if (qName == "title_from_data_file") {
|
||||
fKeyWord = eTitleFromDataFile;
|
||||
} else if (qName == "musrview_show_fourier") {
|
||||
fKeyWord = eMusrviewShowFourier;
|
||||
} else if (qName == "enable_musrt0") {
|
||||
fKeyWord = eEnableMusrT0;
|
||||
} else if (qName == "keep_minuit2_output") {
|
||||
fKeyWord = eKeepMinuit2Output;
|
||||
} else if (qName == "dump_ascii") {
|
||||
fKeyWord = eDumpAscii;
|
||||
} else if (qName == "dump_root") {
|
||||
fKeyWord = eDumpRoot;
|
||||
} else if (qName == "estimate_n0") {
|
||||
fKeyWord = eEstimateN0;
|
||||
} else if (qName == "chisq_per_run_block") {
|
||||
fKeyWord = eChisqPreRunBlock;
|
||||
} else if (qName == "path_file_name") {
|
||||
fKeyWord = eRecentFile;
|
||||
} else if (qName == "beamline") {
|
||||
fKeyWord = eBeamline;
|
||||
} else if (qName == "institute") {
|
||||
fKeyWord = eInstitute;
|
||||
} else if (qName == "file_format") {
|
||||
fKeyWord = eFileFormat;
|
||||
} else if (qName == "lifetime_correction") {
|
||||
fKeyWord = eLifetimeCorrection;
|
||||
} else if (qName == "msr_default_file_path") {
|
||||
fKeyWord = eMsrDefaultFilePath;
|
||||
} else if (qName == "musr_web_main") {
|
||||
fKeyWord = eHelpMain;
|
||||
} else if (qName == "musr_web_title") {
|
||||
fKeyWord = eHelpTitle;
|
||||
} else if (qName == "musr_web_parameters") {
|
||||
fKeyWord = eHelpParameters;
|
||||
} else if (qName == "musr_web_theory") {
|
||||
fKeyWord = eHelpTheory;
|
||||
} else if (qName == "musr_web_functions") {
|
||||
fKeyWord = eHelpFunctions;
|
||||
} else if (qName == "musr_web_run") {
|
||||
fKeyWord = eHelpRun;
|
||||
} else if (qName == "musr_web_command") {
|
||||
fKeyWord = eHelpCommand;
|
||||
} else if (qName == "musr_web_fourier") {
|
||||
fKeyWord = eHelpFourier;
|
||||
} else if (qName == "musr_web_plot") {
|
||||
fKeyWord = eHelpPlot;
|
||||
} else if (qName == "musr_web_statistic") {
|
||||
fKeyWord = eHelpStatistic;
|
||||
} else if (qName == "musr_web_msr2data") {
|
||||
fKeyWord = eHelpMsr2Data;
|
||||
} else if (qName == "musr_web_musrFT") {
|
||||
fKeyWord = eHelpMusrFT;
|
||||
} else if (qName == "chain_fit") {
|
||||
fKeyWord = eChainFit;
|
||||
} else if (qName == "write_data_header") {
|
||||
fKeyWord = eWriteDataHeader;
|
||||
} else if (qName == "ignore_data_header_info") {
|
||||
fKeyWord = eIgnoreDataHeaderInfo;
|
||||
} else if (qName == "keep_minuit2_output") {
|
||||
fKeyWord = eKeepMinuit2Output;
|
||||
} else if (qName == "write_column_data") {
|
||||
fKeyWord = eWriteColumnData;
|
||||
} else if (qName == "recreate_data_file") {
|
||||
fKeyWord = eRecreateDataFile;
|
||||
} else if (qName == "open_file_after_fitting") {
|
||||
fKeyWord = eOpenFileAfterFitting;
|
||||
} else if (qName == "create_msr_file_only") {
|
||||
fKeyWord = eCreateMsrFileOnly;
|
||||
} else if (qName == "fit_only") {
|
||||
fKeyWord = eFitOnly;
|
||||
} else if (qName == "global") {
|
||||
fKeyWord = eGlobal;
|
||||
} else if (qName == "global_plus") {
|
||||
fKeyWord = eGlobalPlus;
|
||||
} else if (qName == "func_pixmap_path") {
|
||||
fKeyWord = eTheoFuncPixmapPath;
|
||||
} else if (qName == "func") {
|
||||
fKeyWord = eFunc;
|
||||
fFunc = true;
|
||||
// init theory item
|
||||
fTheoryItem.name = "";
|
||||
fTheoryItem.comment = "";
|
||||
fTheoryItem.label = "";
|
||||
fTheoryItem.pixmapName = "";
|
||||
fTheoryItem.pixmap = QPixmap();
|
||||
fTheoryItem.params = -1;
|
||||
} else if (qName == "name") {
|
||||
fKeyWord = eFuncName;
|
||||
} else if (qName == "comment") {
|
||||
fKeyWord = eFuncComment;
|
||||
} else if (qName == "label") {
|
||||
fKeyWord = eFuncLabel;
|
||||
} else if (qName == "pixmap") {
|
||||
fKeyWord = eFuncPixmap;
|
||||
} else if (qName == "params") {
|
||||
fKeyWord = eFuncParams;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Routine called when the end XML tag is found. It is used to
|
||||
* put the filtering tag to 'empty'. It also resets the fFunc flag in case
|
||||
* the entry was a theory function.
|
||||
*
|
||||
* \param qName name of the element.
|
||||
*/
|
||||
bool PAdminXMLParser::endElement( const QString&, const QString&, const QString &qName )
|
||||
{
|
||||
fKeyWord = eEmpty;
|
||||
|
||||
if (qName == "func") {
|
||||
fFunc = false;
|
||||
fAdmin->addTheoryItem(fTheoryItem);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This routine delivers the content of an XML tag. It fills the
|
||||
* content into the load data structure.
|
||||
*
|
||||
* \param str keeps the content of the XML tag.
|
||||
*/
|
||||
bool PAdminXMLParser::characters(const QString& str)
|
||||
{
|
||||
QString help;
|
||||
bool flag, ok;
|
||||
int ival;
|
||||
|
||||
switch (fKeyWord) {
|
||||
case eTimeout:
|
||||
ival = QString(str.toLatin1()).trimmed().toInt(&ok);
|
||||
if (ok)
|
||||
fAdmin->setTimeout(ival);
|
||||
break;
|
||||
case eFontName:
|
||||
fAdmin->setFontName(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eFontSize:
|
||||
ival = QString(str.toLatin1()).trimmed().toInt(&ok);
|
||||
if (ok)
|
||||
fAdmin->setFontSize(ival);
|
||||
break;
|
||||
case eExecPath:
|
||||
fAdmin->setExecPath(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eDefaultSavePath:
|
||||
fAdmin->setDefaultSavePath(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eTitleFromDataFile:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setTitleFromDataFileFlag(flag);
|
||||
break;
|
||||
case eMusrviewShowFourier:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setMusrviewShowFourierFlag(flag);
|
||||
break;
|
||||
case eEnableMusrT0:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setEnableMusrT0Flag(flag);
|
||||
break;
|
||||
case eKeepMinuit2Output:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.keepMinuit2Output = flag;
|
||||
fAdmin->setKeepMinuit2OutputFlag(flag);
|
||||
break;
|
||||
case eDumpAscii:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setDumpAsciiFlag(flag);
|
||||
break;
|
||||
case eDumpRoot:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setDumpRootFlag(flag);
|
||||
break;
|
||||
case eEstimateN0:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setEstimateN0Flag(flag);
|
||||
break;
|
||||
case eChisqPreRunBlock:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setChisqPerRunBlockFlag(flag);
|
||||
break;
|
||||
case eRecentFile:
|
||||
fAdmin->addRecentFile(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eBeamline:
|
||||
fAdmin->setBeamline(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eInstitute:
|
||||
fAdmin->setInstitute(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eFileFormat:
|
||||
fAdmin->setFileFormat(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eLifetimeCorrection:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->setLifetimeCorrectionFlag(flag);
|
||||
break;
|
||||
case eMsrDefaultFilePath:
|
||||
fAdmin->setMsrDefaultFilePath(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
case eHelpMain:
|
||||
fAdmin->setHelpUrl("main", str);
|
||||
break;
|
||||
case eHelpTitle:
|
||||
fAdmin->setHelpUrl("title", str);
|
||||
break;
|
||||
case eHelpParameters:
|
||||
fAdmin->setHelpUrl("parameters", str);
|
||||
break;
|
||||
case eHelpTheory:
|
||||
fAdmin->setHelpUrl("theory", str);
|
||||
break;
|
||||
case eHelpFunctions:
|
||||
fAdmin->setHelpUrl("functions", str);
|
||||
break;
|
||||
case eHelpRun:
|
||||
fAdmin->setHelpUrl("run", str);
|
||||
break;
|
||||
case eHelpCommand:
|
||||
fAdmin->setHelpUrl("command", str);
|
||||
break;
|
||||
case eHelpFourier:
|
||||
fAdmin->setHelpUrl("fourier", str);
|
||||
break;
|
||||
case eHelpPlot:
|
||||
fAdmin->setHelpUrl("plot", str);
|
||||
break;
|
||||
case eHelpStatistic:
|
||||
fAdmin->setHelpUrl("statistic", str);
|
||||
break;
|
||||
case eHelpMsr2Data:
|
||||
fAdmin->setHelpUrl("msr2data", str);
|
||||
break;
|
||||
case eHelpMusrFT:
|
||||
fAdmin->setHelpUrl("musrFT", str);
|
||||
break;
|
||||
case eChainFit:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.chainFit = flag;
|
||||
break;
|
||||
case eWriteDataHeader:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.writeDbHeader = flag;
|
||||
break;
|
||||
case eIgnoreDataHeaderInfo:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.ignoreDataHeaderInfo = flag;
|
||||
break;
|
||||
case eWriteColumnData:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.writeColumnData = flag;
|
||||
break;
|
||||
case eRecreateDataFile:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.recreateDbFile = flag;
|
||||
break;
|
||||
case eOpenFileAfterFitting:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.openFilesAfterFitting = flag;
|
||||
break;
|
||||
case eCreateMsrFileOnly:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.createMsrFileOnly = flag;
|
||||
break;
|
||||
case eFitOnly:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.fitOnly = flag;
|
||||
break;
|
||||
case eGlobal:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.global = flag;
|
||||
break;
|
||||
case eGlobalPlus:
|
||||
if (str == "y")
|
||||
flag = true;
|
||||
else
|
||||
flag = false;
|
||||
fAdmin->fMsr2DataParam.globalPlus = flag;
|
||||
break;
|
||||
case eTheoFuncPixmapPath:
|
||||
fAdmin->setTheoFuncPixmapPath(QString(str.toLatin1()).trimmed());
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
if (fFunc) {
|
||||
bool ok;
|
||||
switch (fKeyWord) {
|
||||
case eFuncName:
|
||||
fTheoryItem.name = QString(str.toLatin1()).trimmed();
|
||||
break;
|
||||
case eFuncComment:
|
||||
fTheoryItem.comment = QString(str.toLatin1()).trimmed();
|
||||
break;
|
||||
case eFuncLabel:
|
||||
fTheoryItem.label = QString(str.toLatin1()).trimmed();
|
||||
break;
|
||||
case eFuncPixmap:
|
||||
fTheoryItem.pixmapName = QString(str.toLatin1()).trimmed();
|
||||
break;
|
||||
case eFuncParams:
|
||||
fTheoryItem.params = str.toInt(&ok);
|
||||
if (!ok)
|
||||
return false;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Called at the end of the XML parse process. It checks if default paths
|
||||
* contain system variables, and if so expand them for the further use.
|
||||
*/
|
||||
bool PAdminXMLParser::endDocument()
|
||||
{
|
||||
// check if all necessary items are found
|
||||
QString str;
|
||||
|
||||
if (fAdmin->getExecPath().indexOf('$') >= 0) {
|
||||
str = expandPath(fAdmin->getExecPath());
|
||||
if (!str.isEmpty())
|
||||
fAdmin->setExecPath(str);
|
||||
}
|
||||
|
||||
if (fAdmin->getDefaultSavePath().indexOf('$') >= 0) {
|
||||
str = expandPath(fAdmin->getDefaultSavePath());
|
||||
if (!str.isEmpty())
|
||||
fAdmin->setDefaultSavePath(str);
|
||||
}
|
||||
|
||||
if (fAdmin->getMsrDefaultFilePath().indexOf('$') >= 0) {
|
||||
str = expandPath(fAdmin->getMsrDefaultFilePath());
|
||||
if (!str.isEmpty())
|
||||
fAdmin->setMsrDefaultFilePath(str);
|
||||
}
|
||||
|
||||
if (fAdmin->getTheoFuncPixmapPath().indexOf('$') >=0) {
|
||||
str = expandPath(fAdmin->getTheoFuncPixmapPath());
|
||||
if (!str.isEmpty())
|
||||
fAdmin->setTheoFuncPixmapPath(str);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Report XML warnings.
|
||||
*
|
||||
* \param exception holds the information of the XML warning
|
||||
*/
|
||||
bool PAdminXMLParser::warning( const QXmlParseException & exception )
|
||||
{
|
||||
QString msg;
|
||||
|
||||
msg = QString("**WARNING** while parsing musredit_startup.xml in line no %1\n").arg(exception.lineNumber());
|
||||
msg += QString("**WARNING MESSAGE** ") + exception.message();
|
||||
|
||||
qWarning() << endl << msg << endl;
|
||||
|
||||
QMessageBox::warning(0, "WARNING", msg, QMessageBox::Ok, QMessageBox::NoButton);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Report recoverable XML errors.
|
||||
*
|
||||
* \param exception holds the information of the XML recoverable errors.
|
||||
*/
|
||||
bool PAdminXMLParser::error( const QXmlParseException & exception )
|
||||
{
|
||||
QString msg;
|
||||
|
||||
msg = QString("**ERROR** while parsing musredit_startup.xml in line no %1\n").arg(exception.lineNumber());
|
||||
msg += QString("**ERROR MESSAGE** ") + exception.message();
|
||||
|
||||
qWarning() << endl << msg << endl;
|
||||
|
||||
QMessageBox::critical(0, "ERROR", msg, QMessageBox::Ok, QMessageBox::NoButton);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Report fatal XML errors.
|
||||
*
|
||||
* \param exception holds the information of the XML fatal errors.
|
||||
*/
|
||||
bool PAdminXMLParser::fatalError( const QXmlParseException & exception )
|
||||
{
|
||||
QString msg;
|
||||
|
||||
msg = QString("**FATAL ERROR** while parsing musredit_startup.xml in line no %1\n").arg(exception.lineNumber());
|
||||
msg += QString("**FATAL ERROR MESSAGE** ") + exception.message();
|
||||
|
||||
qWarning() << endl << msg << endl;
|
||||
|
||||
QMessageBox::critical(0, "FATAL ERROR", msg, QMessageBox::Ok, QMessageBox::NoButton);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Expands system variables to full path, e.g. <tt>$HOME -> \home\user</tt>
|
||||
*
|
||||
* \param str path string with none expanded system variables.
|
||||
*/
|
||||
QString PAdminXMLParser::expandPath(const QString &str)
|
||||
{
|
||||
QString token;
|
||||
QString path;
|
||||
QString msg;
|
||||
QString newStr="";
|
||||
|
||||
QStringList list = str.split("/");
|
||||
|
||||
for ( QStringList::Iterator it = list.begin(); it != list.end(); ++it ) {
|
||||
token = *it;
|
||||
if (token.contains("$")) {
|
||||
token.remove('$');
|
||||
path = std::getenv(token.toLatin1());
|
||||
if (path.isEmpty()) {
|
||||
msg = QString("Couldn't expand '%1'. Some things might not work properly").arg(token);
|
||||
QMessageBox::warning(0, "**WARNING**", msg, QMessageBox::Ok, QMessageBox::NoButton);
|
||||
newStr = "";
|
||||
break;
|
||||
}
|
||||
newStr += path;
|
||||
} else {
|
||||
newStr += "/" + token;
|
||||
}
|
||||
}
|
||||
|
||||
return newStr;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// implementation of PAdmin class
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Initializes that PAdmin object, and calls the XML parser which feeds
|
||||
* the object variables.
|
||||
*/
|
||||
PAdmin::PAdmin() : QObject()
|
||||
{
|
||||
fTimeout = 3600;
|
||||
|
||||
fFontName = QString("Courier"); // default font
|
||||
fFontSize = 11; // default font size
|
||||
|
||||
fExecPath = QString("");
|
||||
fDefaultSavePath = QString("");
|
||||
fMsrDefaultFilePath = QString("");
|
||||
fTheoFuncPixmapPath = QString("");
|
||||
|
||||
fBeamline = QString("");
|
||||
fInstitute = QString("");
|
||||
fFileFormat = QString("");
|
||||
|
||||
fMusrviewShowFourier = false;
|
||||
|
||||
fTitleFromDataFile = false;
|
||||
fEnableMusrT0 = false;
|
||||
fLifetimeCorrection = true;
|
||||
fEstimateN0 = true;
|
||||
fChisqPreRunBlock = false;
|
||||
|
||||
fMsr2DataParam.firstRun = -1;
|
||||
fMsr2DataParam.lastRun = -1;
|
||||
fMsr2DataParam.runList = QString("");
|
||||
fMsr2DataParam.runListFileName = QString("");
|
||||
fMsr2DataParam.msrFileExtension = QString("");
|
||||
fMsr2DataParam.templateRunNo = -1;
|
||||
fMsr2DataParam.dbOutputFileName = QString("");
|
||||
fMsr2DataParam.writeDbHeader = true;
|
||||
fMsr2DataParam.ignoreDataHeaderInfo = false;
|
||||
fMsr2DataParam.keepMinuit2Output = false;
|
||||
fMsr2DataParam.writeColumnData = false;
|
||||
fMsr2DataParam.recreateDbFile = false;
|
||||
fMsr2DataParam.chainFit = true;
|
||||
fMsr2DataParam.openFilesAfterFitting = true;
|
||||
fMsr2DataParam.titleFromDataFile = true;
|
||||
fMsr2DataParam.createMsrFileOnly = false;
|
||||
fMsr2DataParam.fitOnly = false;
|
||||
fMsr2DataParam.global = false;
|
||||
fMsr2DataParam.globalPlus = false;
|
||||
|
||||
// XML Parser part
|
||||
QString fln = "musredit_startup.xml";
|
||||
// check if it is a MacOSX
|
||||
#ifdef Q_WS_MAC
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
fln = "/Applications/musredit.app/Contents/Resources/musredit_startup.xml";
|
||||
}
|
||||
#else
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
QString path = std::getenv("MUSRFITPATH");
|
||||
QString rootsys = std::getenv("ROOTSYS");
|
||||
if (path.isEmpty())
|
||||
path = rootsys + "/bin";
|
||||
fln = path + "/musredit_startup.xml";
|
||||
}
|
||||
#endif
|
||||
|
||||
loadPrefs(fln);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Destructor
|
||||
*/
|
||||
PAdmin::~PAdmin()
|
||||
{
|
||||
saveRecentFiles();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the help url corresponding the the tag.
|
||||
*
|
||||
* \param tag to map the help url. At the moment the following tags should be present:
|
||||
* main, title, parameters, theory, functions, run, command, fourier, plot, statistic
|
||||
*/
|
||||
QString PAdmin::getHelpUrl(QString tag)
|
||||
{
|
||||
return fHelpUrl[tag];
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a theory item from position idx. If idx is out of the range, a null pointer is returned.
|
||||
*
|
||||
* \param idx position of the theory item.
|
||||
*/
|
||||
PTheory* PAdmin::getTheoryItem(const unsigned int idx)
|
||||
{
|
||||
if (idx > (unsigned int)fTheory.size())
|
||||
return 0;
|
||||
else
|
||||
return &fTheory[idx];
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the recent path-file name at position idx. If idx is out of scope,
|
||||
* an empty string is returned.
|
||||
*
|
||||
* \param idx index of the recent path-file name to be retrieved.
|
||||
*/
|
||||
QString PAdmin::getRecentFile(int idx)
|
||||
{
|
||||
if (idx >= fRecentFile.size())
|
||||
return QString("");
|
||||
|
||||
return fRecentFile[idx];
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>set the help url, addressed via a tag. At the moment the following tags should be present:
|
||||
* main, title, parameters, theory, functions, run, command, fourier, plot, statistic, msr2data
|
||||
*
|
||||
* \param tag to address the help url
|
||||
* \param url help url corresponding to the tag.
|
||||
*/
|
||||
void PAdmin::setHelpUrl(const QString tag, const QString url)
|
||||
{
|
||||
fHelpUrl[tag] = url;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Loads the preference file fln.
|
||||
*
|
||||
* <b>return:</b> 1 on success, 0 otherwise
|
||||
*
|
||||
* \param fln path-file name of the preference file to be loaded.
|
||||
*/
|
||||
int PAdmin::loadPrefs(QString fln)
|
||||
{
|
||||
if (QFile::exists(fln)) { // administration file present
|
||||
PAdminXMLParser handler(this);
|
||||
QFile xmlFile(fln);
|
||||
QXmlInputSource source( &xmlFile );
|
||||
QXmlSimpleReader reader;
|
||||
reader.setContentHandler( &handler );
|
||||
reader.setErrorHandler( &handler );
|
||||
if (!reader.parse( source )) {
|
||||
QMessageBox::critical(0, "ERROR",
|
||||
"Error parsing musredit_startup.xml settings file.\nProbably a few things will not work porperly.\nPlease fix this first.",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return 0;
|
||||
}
|
||||
} else {
|
||||
QMessageBox::critical(0, "ERROR",
|
||||
"Couldn't find the musredit_startup.xml settings file.\nProbably a few things will not work porperly.\nPlease fix this first.",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return 0;
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Save the preference file pref_fln.
|
||||
*
|
||||
* <b>return:</b> 1 on success, 0 otherwise
|
||||
*
|
||||
* \param pref_fln preference path-file name
|
||||
*/
|
||||
int PAdmin::savePrefs(QString pref_fln)
|
||||
{
|
||||
// check if musredit_startup.xml is present in the current directory, and if yes, use this file to
|
||||
// save the recent file names otherwise use the "master" musredit_startup.xml
|
||||
|
||||
QString str;
|
||||
QString fln = "musredit_startup.xml";
|
||||
// check if it is a MacOSX
|
||||
#ifdef Q_WS_MAC
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
fln = "/Applications/musredit.app/Contents/Resources/musredit_startup.xml";
|
||||
}
|
||||
#else
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
QString path = std::getenv("MUSRFITPATH");
|
||||
QString rootsys = std::getenv("ROOTSYS");
|
||||
if (path.isEmpty())
|
||||
path = rootsys + "/bin";
|
||||
fln = path + "/musredit_startup.xml";
|
||||
}
|
||||
#endif
|
||||
if (QFile::exists(fln)) { // administration file present
|
||||
QVector<QString> data;
|
||||
QFile file(fln);
|
||||
if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
|
||||
cerr << endl << ">> PAdmin::savePrefs: **ERROR** Cannot open " << fln.toLatin1().data() << " for reading." << endl;
|
||||
return 1;
|
||||
}
|
||||
QTextStream fin(&file);
|
||||
while (!fin.atEnd()) {
|
||||
data.push_back(fin.readLine());
|
||||
}
|
||||
file.close();
|
||||
|
||||
// replace all the prefs
|
||||
for (int i=0; i<data.size(); i++) {
|
||||
if (data[i].contains("<timeout>") && data[i].contains("</timeout>")) {
|
||||
data[i] = " <timeout>" + QString("%1").arg(fTimeout) + "</timeout>";
|
||||
}
|
||||
if (data[i].contains("<keep_minuit2_output>") && data[i].contains("</keep_minuit2_output>")) {
|
||||
if (fKeepMinuit2Output)
|
||||
data[i] = " <keep_minuit2_output>y</keep_minuit2_output>";
|
||||
else
|
||||
data[i] = " <keep_minuit2_output>n</keep_minuit2_output>";
|
||||
}
|
||||
if (data[i].contains("<dump_ascii>") && data[i].contains("</dump_ascii>")) {
|
||||
if (fDumpAscii)
|
||||
data[i] = " <dump_ascii>y</dump_ascii>";
|
||||
else
|
||||
data[i] = " <dump_ascii>n</dump_ascii>";
|
||||
}
|
||||
if (data[i].contains("<dump_root>") && data[i].contains("</dump_root>")) {
|
||||
if (fDumpRoot)
|
||||
data[i] = " <dump_root>y</dump_root>";
|
||||
else
|
||||
data[i] = " <dump_root>n</dump_root>";
|
||||
}
|
||||
if (data[i].contains("<title_from_data_file>") && data[i].contains("</title_from_data_file>")) {
|
||||
if (fTitleFromDataFile)
|
||||
data[i] = " <title_from_data_file>y</title_from_data_file>";
|
||||
else
|
||||
data[i] = " <title_from_data_file>n</title_from_data_file>";
|
||||
}
|
||||
if (data[i].contains("<chisq_per_run_block>") && data[i].contains("</chisq_per_run_block>")) {
|
||||
if (fChisqPreRunBlock)
|
||||
data[i] = " <chisq_per_run_block>y</chisq_per_run_block>";
|
||||
else
|
||||
data[i] = " <chisq_per_run_block>n</chisq_per_run_block>";
|
||||
}
|
||||
if (data[i].contains("<estimate_n0>") && data[i].contains("</estimate_n0>")) {
|
||||
if (fEstimateN0)
|
||||
data[i] = " <estimate_n0>y</estimate_n0>";
|
||||
else
|
||||
data[i] = " <estimate_n0>n</estimate_n0>";
|
||||
}
|
||||
if (data[i].contains("<enable_musrt0>") && data[i].contains("</enable_musrt0>")) {
|
||||
if (fEnableMusrT0)
|
||||
data[i] = " <enable_musrt0>y</enable_musrt0>";
|
||||
else
|
||||
data[i] = " <enable_musrt0>n</enable_musrt0>";
|
||||
}
|
||||
}
|
||||
|
||||
// write prefs
|
||||
file.setFileName(pref_fln);
|
||||
if (!file.open(QIODevice::WriteOnly | QIODevice::Text)) {
|
||||
cerr << endl << ">> PAdmin::savePrefs: **ERROR** Cannot open " << fln.toLatin1().data() << " for writing." << endl;
|
||||
return 0;
|
||||
}
|
||||
fin.setDevice(&file);
|
||||
for (int i=0; i<data.size(); i++)
|
||||
fin << data[i] << endl;
|
||||
file.close();
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Add recent path-file name to the internal ring-buffer.
|
||||
*
|
||||
* \param str recent path-file name to be added
|
||||
*/
|
||||
void PAdmin::addRecentFile(const QString str)
|
||||
{
|
||||
// check if file name is not already present
|
||||
for (int i=0; i<fRecentFile.size(); i++) {
|
||||
if (str == fRecentFile[i])
|
||||
return;
|
||||
}
|
||||
|
||||
fRecentFile.push_front(str);
|
||||
if (fRecentFile.size() > MAX_RECENT_FILES)
|
||||
fRecentFile.resize(MAX_RECENT_FILES);
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Merges the recent file ring buffer into musredit_startup.xml and saves it.
|
||||
* If a local copy is present it will be saved there, otherwise the master file
|
||||
* will be used.
|
||||
*/
|
||||
void PAdmin::saveRecentFiles()
|
||||
{
|
||||
// check if musredit_startup.xml is present in the current directory, and if yes, use this file to
|
||||
// save the recent file names otherwise use the "master" musredit_startup.xml
|
||||
|
||||
QString str;
|
||||
QString fln = "musredit_startup.xml";
|
||||
// check if it is a MacOSX
|
||||
#ifdef Q_WS_MAC
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
fln = "/Applications/musredit.app/Contents/Resources/musredit_startup.xml";
|
||||
}
|
||||
#else
|
||||
fln = "./musredit_startup.xml";
|
||||
if (!QFile::exists(fln)) {
|
||||
QString path = std::getenv("MUSRFITPATH");
|
||||
QString rootsys = std::getenv("ROOTSYS");
|
||||
if (path.isEmpty())
|
||||
path = rootsys + "/bin";
|
||||
fln = path + "/musredit_startup.xml";
|
||||
}
|
||||
#endif
|
||||
if (QFile::exists(fln)) { // administration file present
|
||||
QVector<QString> data;
|
||||
QFile file(fln);
|
||||
if (!file.open(QIODevice::ReadOnly | QIODevice::Text)) {
|
||||
cerr << endl << ">> PAdmin::saveRecentFile: **ERROR** Cannot open " << fln.toLatin1().data() << " for reading." << endl;
|
||||
return;
|
||||
}
|
||||
QTextStream fin(&file);
|
||||
while (!fin.atEnd()) {
|
||||
data.push_back(fin.readLine());
|
||||
}
|
||||
file.close();
|
||||
|
||||
// remove <path_file_name> from data
|
||||
for (QVector<QString>::iterator it = data.begin(); it != data.end(); ++it) {
|
||||
if (it->contains("<path_file_name>")) {
|
||||
it = data.erase(it);
|
||||
--it;
|
||||
}
|
||||
}
|
||||
|
||||
// add recent files
|
||||
int i;
|
||||
for (i=0; i<data.size(); i++) {
|
||||
if (data[i].contains("<recent_files>"))
|
||||
break;
|
||||
}
|
||||
|
||||
if (i == data.size()) {
|
||||
cerr << endl << ">> PAdmin::saveRecentFile: **ERROR** " << fln.toLatin1().data() << " seems to be corrupt." << endl;
|
||||
return;
|
||||
}
|
||||
i++;
|
||||
for (int j=0; j<fRecentFile.size(); j++) {
|
||||
str = " <path_file_name>" + fRecentFile[j] + "</path_file_name>";
|
||||
data.insert(i++, str);
|
||||
}
|
||||
|
||||
if (!file.open(QIODevice::WriteOnly | QIODevice::Text)) {
|
||||
cerr << endl << ">> PAdmin::saveRecentFile: **ERROR** Cannot open " << fln.toLatin1().data() << " for reading." << endl;
|
||||
return;
|
||||
}
|
||||
fin.setDevice(&file);
|
||||
for (int i=0; i<data.size(); i++)
|
||||
fin << data[i] << endl;
|
||||
file.close();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
// END
|
||||
//--------------------------------------------------------------------------
|
208
src/musredit_qt5/PAdmin.h
Normal file
@ -0,0 +1,208 @@
|
||||
/****************************************************************************
|
||||
|
||||
PAdmin.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PADMIN_H_
|
||||
#define _PADMIN_H_
|
||||
|
||||
#include <QString>
|
||||
#include <QVector>
|
||||
#include <QMap>
|
||||
#include <QPixmap>
|
||||
#include <QtXml>
|
||||
|
||||
#include <musredit.h>
|
||||
|
||||
class PAdmin;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This structure is keeping informations necessary to handle musrfit
|
||||
* theory functions (see also <code>https://intranet.psi.ch/MUSR/MusrFit#4_3_The_THEORY_Block</code>).
|
||||
*/
|
||||
typedef struct {
|
||||
QString name;
|
||||
QString comment;
|
||||
QString label;
|
||||
QString pixmapName;
|
||||
QPixmap pixmap;
|
||||
int params;
|
||||
} PTheory;
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* PAdminXMLParser is an XML parser class used to handle the musredit startup
|
||||
* XML-file called <tt>musredit_startup.xml</tt>. This startup file contains
|
||||
* necessary informations about executable pathes, online help informations,
|
||||
* default font sizes, etc.
|
||||
*/
|
||||
class PAdminXMLParser : public QXmlDefaultHandler
|
||||
{
|
||||
public:
|
||||
PAdminXMLParser(PAdmin*);
|
||||
virtual ~PAdminXMLParser() {}
|
||||
|
||||
private:
|
||||
enum EAdminKeyWords {eEmpty, eTimeout, eKeepMinuit2Output, eDumpAscii, eDumpRoot,
|
||||
eTitleFromDataFile, eChisqPreRunBlock, eEstimateN0, eMusrviewShowFourier, eEnableMusrT0,
|
||||
eFontName, eFontSize, eExecPath, eDefaultSavePath,
|
||||
eRecentFile, eBeamline, eInstitute, eFileFormat, eLifetimeCorrection, eMsrDefaultFilePath,
|
||||
eTheoFuncPixmapPath, eFunc, eFuncName, eFuncComment, eFuncLabel,
|
||||
eFuncPixmap, eFuncParams, eHelpMain, eHelpTitle, eHelpParameters, eHelpTheory, eHelpFunctions,
|
||||
eHelpRun, eHelpCommand, eHelpFourier, eHelpPlot, eHelpStatistic, eHelpMsr2Data, eHelpMusrFT,
|
||||
eChainFit, eWriteDataHeader, eIgnoreDataHeaderInfo, eWriteColumnData,
|
||||
eRecreateDataFile, eOpenFileAfterFitting, eCreateMsrFileOnly, eFitOnly, eGlobal, eGlobalPlus};
|
||||
|
||||
bool startDocument();
|
||||
bool startElement( const QString&, const QString&, const QString& ,
|
||||
const QXmlAttributes& );
|
||||
bool endElement( const QString&, const QString&, const QString& );
|
||||
|
||||
bool characters(const QString&);
|
||||
bool endDocument();
|
||||
|
||||
bool warning( const QXmlParseException & exception );
|
||||
bool error( const QXmlParseException & exception );
|
||||
bool fatalError( const QXmlParseException & exception );
|
||||
|
||||
QString expandPath(const QString&);
|
||||
|
||||
EAdminKeyWords fKeyWord; ///< key word tag to know how to handle the content
|
||||
bool fFunc; ///< flag needed to indicate that a new theory function is found
|
||||
PTheory fTheoryItem; ///< holding the informations necessary for a theory item
|
||||
PAdmin *fAdmin; ///< a pointer to the main administration class object
|
||||
};
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* The PAdmin class is handling the informations contained in the XML startup file,
|
||||
* <tt>musredit_startup.xml</tt>. This startup file contains
|
||||
* necessary informations about executable pathes, online help informations,
|
||||
* default font sizes, etc. The XML parsing is done with the help of the PAdminXMLParser
|
||||
* class.
|
||||
*/
|
||||
class PAdmin : public QObject
|
||||
{
|
||||
public:
|
||||
PAdmin();
|
||||
virtual ~PAdmin();
|
||||
|
||||
int getTimeout() { return fTimeout; }
|
||||
QString getFontName() { return fFontName; }
|
||||
int getFontSize() { return fFontSize; }
|
||||
QString getExecPath() { return fExecPath; }
|
||||
QString getDefaultSavePath() { return fDefaultSavePath; }
|
||||
bool getTitleFromDataFileFlag() { return fTitleFromDataFile; }
|
||||
bool getMusrviewShowFourierFlag() { return fMusrviewShowFourier; }
|
||||
bool getEnableMusrT0Flag() { return fEnableMusrT0; }
|
||||
bool getKeepMinuit2OutputFlag() { return fKeepMinuit2Output; }
|
||||
bool getDumpAsciiFlag() { return fDumpAscii; }
|
||||
bool getDumpRootFlag() { return fDumpRoot; }
|
||||
bool getEstimateN0Flag() { return fEstimateN0; }
|
||||
bool getChisqPerRunBlockFlag() { return fChisqPreRunBlock; }
|
||||
QString getBeamline() { return fBeamline; }
|
||||
QString getInstitute() { return fInstitute; }
|
||||
QString getFileFormat() { return fFileFormat; }
|
||||
bool getLifetimeCorrectionFlag() { return fLifetimeCorrection; }
|
||||
QString getMsrDefaultFilePath() { return fMsrDefaultFilePath; }
|
||||
QString getHelpUrl(QString tag);
|
||||
QString getTheoFuncPixmapPath() { return fTheoFuncPixmapPath; }
|
||||
unsigned int getTheoryCounts() { return fTheory.size(); }
|
||||
PTheory* getTheoryItem(const unsigned int idx);
|
||||
PMsr2DataParam getMsr2DataParam() { return fMsr2DataParam; }
|
||||
int getNumRecentFiles() { return fRecentFile.size(); }
|
||||
QString getRecentFile(int idx);
|
||||
|
||||
void setTimeout(const int ival) { fTimeout = ival; }
|
||||
void setTitleFromDataFileFlag(const bool flag) { fTitleFromDataFile = flag; }
|
||||
void setMusrviewShowFourierFlag(const bool flag) { fMusrviewShowFourier = flag; }
|
||||
void setEnableMusrT0Flag(const bool flag) { fEnableMusrT0 = flag; }
|
||||
void setKeepMinuit2OutputFlag(const bool flag) { fKeepMinuit2Output = flag; }
|
||||
void setDumpAsciiFlag(const bool flag) { fDumpAscii = flag; }
|
||||
void setDumpRootFlag(const bool flag) { fDumpRoot = flag; }
|
||||
void setEstimateN0Flag(const bool flag) { fEstimateN0 = flag; }
|
||||
void setChisqPerRunBlockFlag(const bool flag) { fChisqPreRunBlock = flag; }
|
||||
|
||||
void setFontName(const QString str) { fFontName = str; }
|
||||
void setFontSize(const int ival) { fFontSize = ival; }
|
||||
void addRecentFile(const QString str);
|
||||
|
||||
int loadPrefs(QString fln);
|
||||
int savePrefs(QString pref_fln);
|
||||
|
||||
protected:
|
||||
void setExecPath(const QString str) { fExecPath = str; }
|
||||
void setDefaultSavePath(const QString str) { fDefaultSavePath = str; }
|
||||
void setBeamline(const QString str) { fBeamline = str; }
|
||||
void setInstitute(const QString str) { fInstitute = str; }
|
||||
void setFileFormat(const QString str) { fFileFormat = str; }
|
||||
void setLifetimeCorrectionFlag(const bool flag) { fLifetimeCorrection = flag; }
|
||||
void setMsrDefaultFilePath(const QString str) { fMsrDefaultFilePath = str; }
|
||||
void setHelpUrl(const QString tag, const QString url);
|
||||
void setTheoFuncPixmapPath (const QString str) { fTheoFuncPixmapPath = str; }
|
||||
void addTheoryItem(const PTheory theo) { fTheory.push_back(theo); }
|
||||
|
||||
private:
|
||||
friend class PAdminXMLParser;
|
||||
|
||||
int fTimeout; ///< timeout in seconds
|
||||
|
||||
QString fFontName; ///< default font name
|
||||
int fFontSize; ///< default font size
|
||||
|
||||
QString fExecPath; ///< system path to the musrfit executables
|
||||
QString fDefaultSavePath; ///< default path where the msr-file should be saved
|
||||
QString fMsrDefaultFilePath; ///< path where to find musredit source
|
||||
QString fTheoFuncPixmapPath; ///< path where the default pixmaps can be found
|
||||
|
||||
QVector<QString> fRecentFile; ///< keep vector of recent path-file names
|
||||
|
||||
bool fMusrviewShowFourier; ///< flag indicating if musrview should show at startup data (=false) or Fourier of data (=true).
|
||||
bool fKeepMinuit2Output; ///< flag indicating if the Minuit2 output shall be kept (default: no)
|
||||
bool fDumpAscii; ///< flag indicating if musrfit shall make an ascii-dump file (for debugging purposes, default: no).
|
||||
bool fDumpRoot; ///< flag indicating if musrfit shall make an root-dump file (for debugging purposes, default: no).
|
||||
bool fTitleFromDataFile; ///< flag indicating if the title should be extracted from the data file (default: yes).
|
||||
bool fChisqPreRunBlock; ///< flag indicating if musrfit shall write 'per run block' chisq to the msr-file (default: no).
|
||||
bool fEstimateN0; ///< flag indicating if musrfit shall estimate N0 for single histogram fits (default: yes).
|
||||
bool fEnableMusrT0; ///< flag indicating if musrT0 shall be enabled at startup from within musredit (default: yes).
|
||||
|
||||
QString fBeamline; ///< name of the beamline. Used to generate default run header lines.
|
||||
QString fInstitute; ///< name of the institute. Used to generate default run header lines.
|
||||
QString fFileFormat; ///< default file format. Used to generate default run header lines.
|
||||
bool fLifetimeCorrection; ///< flag indicating if by default the lifetime-correction-flag in a single histo file shall be set.
|
||||
|
||||
mutable PMsr2DataParam fMsr2DataParam; ///< keeps msr2data default parameter flags
|
||||
|
||||
QMap<QString, QString> fHelpUrl; ///< maps tag to help url
|
||||
|
||||
QVector<PTheory> fTheory; ///< stores all known theories. Needed when generating theory blocks from within musredit.
|
||||
|
||||
void saveRecentFiles(); ///< save recent file list
|
||||
};
|
||||
|
||||
#endif // _PADMIN_H_
|
153
src/musredit_qt5/PDumpOutputHandler.cpp
Normal file
@ -0,0 +1,153 @@
|
||||
/****************************************************************************
|
||||
|
||||
PDumpOutputHandler.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2012-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QTimer>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
#include "PDumpOutputHandler.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Sets up the dump output handler GUI and starts the actual dump_header command
|
||||
*
|
||||
* \param cmd command string vector. From this the actual dump_header command will be generated and executed.
|
||||
*/
|
||||
PDumpOutputHandler::PDumpOutputHandler(QVector<QString> &cmd)
|
||||
{
|
||||
if (cmd.empty())
|
||||
return;
|
||||
|
||||
// Layout
|
||||
fVbox = new QVBoxLayout( this );
|
||||
fOutput = new QTextEdit();
|
||||
fVbox->addWidget(fOutput);
|
||||
fOutput->setMinimumSize(600, 755);
|
||||
fOutput->setReadOnly(true);
|
||||
connect( fOutput, SIGNAL( destroyed() ), this, SLOT( quitButtonPressed() ) );
|
||||
fQuitButton = new QPushButton( tr("Quit") );
|
||||
fVbox->addWidget(fQuitButton);
|
||||
connect( fQuitButton, SIGNAL( clicked() ), this, SLOT( quitButtonPressed() ) );
|
||||
resize( 600, 800 );
|
||||
fQuitButton->setFocus();
|
||||
|
||||
// QProcess related code
|
||||
fProc = new QProcess( this );
|
||||
|
||||
// Set up the command and arguments.
|
||||
QString program = cmd[0];
|
||||
QStringList arguments;
|
||||
for (int i=1; i<cmd.size(); i++)
|
||||
arguments << cmd[i];
|
||||
|
||||
connect( fProc, SIGNAL( readyReadStandardOutput() ), this, SLOT( readFromStdOut() ) );
|
||||
connect( fProc, SIGNAL( readyReadStandardError() ), this, SLOT( readFromStdErr() ) );
|
||||
|
||||
fProc->start(program, arguments);
|
||||
if ( !fProc->waitForStarted() ) {
|
||||
// error handling
|
||||
QString msg(tr("Could not execute the output command: ")+cmd[0]);
|
||||
QMessageBox::critical( 0,
|
||||
tr("Fatal error"),
|
||||
msg,
|
||||
tr("Quit") );
|
||||
done(0);
|
||||
}
|
||||
fProcPID = fProc->pid();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Destructor. Checks if the a dump_header is still running and if yes try to kill it.
|
||||
*/
|
||||
PDumpOutputHandler::~PDumpOutputHandler()
|
||||
{
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
fProc->terminate();
|
||||
if (!fProc->waitForFinished()) {
|
||||
qDebug() << "fProc still running, will call kill." << endl;
|
||||
fProc->kill();
|
||||
}
|
||||
fProc->waitForFinished();
|
||||
}
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
QString cmd = "kill -9 "+ fProcPID;
|
||||
QString msg = "fProc still running even after Qt kill, will try system kill cmd: "+cmd;
|
||||
qDebug() << msg << endl;
|
||||
system(cmd.toLatin1());
|
||||
}
|
||||
if (fProc) {
|
||||
delete fProc;
|
||||
fProc = 0;
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Captures the standard output and adds it to the output text edit.
|
||||
*/
|
||||
void PDumpOutputHandler::readFromStdOut()
|
||||
{
|
||||
// Read and process the data.
|
||||
// Bear in mind that the data might be output in chunks.
|
||||
fOutput->append( fProc->readAllStandardOutput() );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Captures the standard error and adds it to the output text edit.
|
||||
*/
|
||||
void PDumpOutputHandler::readFromStdErr()
|
||||
{
|
||||
// Read and process the data.
|
||||
// Bear in mind that the data might be output in chunks.
|
||||
fOutput->append( fProc->readAllStandardError() );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>If the quit button is pressed while the dump_header is still running, try to terminate dump_header, if this
|
||||
* does not work, try to kill dump_header.
|
||||
*/
|
||||
void PDumpOutputHandler::quitButtonPressed()
|
||||
{
|
||||
// if the fitting is still taking place, kill it
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
fProc->terminate();
|
||||
if (!fProc->waitForFinished()) {
|
||||
fProc->kill();
|
||||
}
|
||||
}
|
||||
|
||||
accept();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
72
src/musredit_qt5/PDumpOutputHandler.h
Normal file
@ -0,0 +1,72 @@
|
||||
/****************************************************************************
|
||||
|
||||
PDumpOutputHandler.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2012-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PDUMPOUTPUTHANDLER_H_
|
||||
#define _PDUMPOUTPUTHANDLER_H_
|
||||
|
||||
#include <QObject>
|
||||
#include <QProcess>
|
||||
#include <QDialog>
|
||||
#include <QVBoxLayout>
|
||||
#include <QTextEdit>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
#include <QVector>
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
//---------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This class is the capturing the output of musrfit and displays it in a dialog so
|
||||
* the user has the chance to follow the fitting process, warnings, error messages of
|
||||
* musrfit.
|
||||
*/
|
||||
class PDumpOutputHandler : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PDumpOutputHandler(QVector<QString> &cmd);
|
||||
virtual ~PDumpOutputHandler();
|
||||
|
||||
private slots:
|
||||
virtual void readFromStdOut();
|
||||
virtual void readFromStdErr();
|
||||
virtual void quitButtonPressed();
|
||||
|
||||
private:
|
||||
Q_PID fProcPID; ///< keeps the process PID
|
||||
QProcess *fProc; ///< pointer to the dump_header process
|
||||
|
||||
QVBoxLayout *fVbox; ///< pointer to the dialog layout manager
|
||||
QTextEdit *fOutput; ///< the captured dump_header output is written (read only) into this text edit object.
|
||||
QPushButton *fQuitButton; ///< quit button
|
||||
};
|
||||
|
||||
#endif // _PDUMPOUTPUTHANDLER_H_
|
108
src/musredit_qt5/PFindDialog.cpp
Normal file
@ -0,0 +1,108 @@
|
||||
/****************************************************************************
|
||||
|
||||
PFindDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QPushButton>
|
||||
#include <QComboBox>
|
||||
#include <QCheckBox>
|
||||
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PFindDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Sets up the find dialog.
|
||||
*
|
||||
* \param data pointer to the find/replace data structure needed to perform the task.
|
||||
* \param selection flag indicating if the find shall be restricted to the selected area
|
||||
* \param parent pointer to the parent object
|
||||
* \param f qt specific window flags
|
||||
*/
|
||||
PFindDialog::PFindDialog(PFindReplaceData *data, const bool selection, QWidget *parent, Qt::WindowFlags f) :
|
||||
QDialog(parent, f), fData(data)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
// if only empty text, disable find button
|
||||
if (fData->findText == "") {
|
||||
fFind_pushButton->setEnabled(false);
|
||||
}
|
||||
|
||||
// if there is no selection, disable that option
|
||||
if (!selection) {
|
||||
fSelectedText_checkBox->setChecked(false);
|
||||
fSelectedText_checkBox->setEnabled(false);
|
||||
}
|
||||
|
||||
fFind_comboBox->setItemText(0, fData->findText);
|
||||
fCaseSensitive_checkBox->setChecked(fData->caseSensitive);
|
||||
fWholeWordsOnly_checkBox->setChecked(fData->wholeWordsOnly);
|
||||
fFromCursor_checkBox->setChecked(fData->fromCursor);
|
||||
fFindBackwards_checkBox->setChecked(fData->findBackwards);
|
||||
|
||||
if (selection) {
|
||||
fSelectedText_checkBox->setChecked(fData->selectedText);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts all the necessary informations from the find dialog, feeds it to the find/replace
|
||||
* structure and returns a point to this structure.
|
||||
*/
|
||||
PFindReplaceData* PFindDialog::getData()
|
||||
{
|
||||
fData->findText = fFind_comboBox->currentText();
|
||||
fData->caseSensitive = fCaseSensitive_checkBox->isChecked();
|
||||
fData->wholeWordsOnly = fWholeWordsOnly_checkBox->isChecked();
|
||||
fData->fromCursor = fFromCursor_checkBox->isChecked();
|
||||
fData->findBackwards = fFindBackwards_checkBox->isChecked();
|
||||
if (fSelectedText_checkBox->isEnabled())
|
||||
fData->selectedText = fSelectedText_checkBox->isChecked();
|
||||
|
||||
return fData;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Enables the find button only if there is any find text entered.
|
||||
*/
|
||||
void PFindDialog::onFindTextAvailable(const QString&)
|
||||
{
|
||||
if (fFind_comboBox->currentText() != "")
|
||||
fFind_pushButton->setEnabled(true);
|
||||
else
|
||||
fFind_pushButton->setEnabled(false);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
57
src/musredit_qt5/PFindDialog.h
Normal file
@ -0,0 +1,57 @@
|
||||
/****************************************************************************
|
||||
|
||||
PFindDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PFINDDIALOG_H_
|
||||
#define _PFINDDIALOG_H_
|
||||
|
||||
#include "musredit.h"
|
||||
#include "ui_PFindDialog.h"
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>PFindDialog is the class handling the find dialog.
|
||||
*/
|
||||
class PFindDialog : public QDialog, private Ui::PFindDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PFindDialog(PFindReplaceData *data, const bool selection, QWidget *parent = 0, Qt::WindowFlags f = 0);
|
||||
virtual ~PFindDialog() {}
|
||||
|
||||
virtual PFindReplaceData *getData();
|
||||
|
||||
protected slots:
|
||||
virtual void onFindTextAvailable(const QString&);
|
||||
|
||||
private:
|
||||
PFindReplaceData *fData; ///< stores the data necessary to perform find/replace.
|
||||
};
|
||||
|
||||
#endif // _PFINDDIALOG_H_
|
172
src/musredit_qt5/PFitOutputHandler.cpp
Normal file
@ -0,0 +1,172 @@
|
||||
/****************************************************************************
|
||||
|
||||
PFitOutputHandler.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QTimer>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
#include "PFitOutputHandler.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Sets up the fit output handler GUI and starts the actual fit
|
||||
*
|
||||
* \param workingDirectory string holding the working directory wished. In this directory the mlog-file will be saved.
|
||||
* \param cmd command string vector. From this the actuall fit command will be generated and executed.
|
||||
*/
|
||||
PFitOutputHandler::PFitOutputHandler(QString workingDirectory, QVector<QString> &cmd)
|
||||
{
|
||||
if (cmd.empty())
|
||||
return;
|
||||
|
||||
// Layout
|
||||
fVbox = new QVBoxLayout( this );
|
||||
//Qt.3x fVbox->resize(800, 500);
|
||||
fOutput = new QTextEdit();
|
||||
fVbox->addWidget(fOutput);
|
||||
fOutput->setMinimumSize(800, 455);
|
||||
fOutput->setReadOnly(true);
|
||||
connect( fOutput, SIGNAL( destroyed() ), this, SLOT( quitButtonPressed() ) );
|
||||
fQuitButton = new QPushButton( tr("Fitting...") );
|
||||
fVbox->addWidget(fQuitButton);
|
||||
connect( fQuitButton, SIGNAL( clicked() ), this, SLOT( quitButtonPressed() ) );
|
||||
resize( 800, 500 );
|
||||
fQuitButton->setFocus();
|
||||
|
||||
// QProcess related code
|
||||
fProc = new QProcess( this );
|
||||
|
||||
fProc->setWorkingDirectory(workingDirectory);
|
||||
|
||||
// Set up the command and arguments.
|
||||
QString program = cmd[0];
|
||||
QStringList arguments;
|
||||
for (int i=1; i<cmd.size(); i++)
|
||||
arguments << cmd[i];
|
||||
|
||||
connect( fProc, SIGNAL( readyReadStandardOutput() ), this, SLOT( readFromStdOut() ) );
|
||||
connect( fProc, SIGNAL( readyReadStandardError() ), this, SLOT( readFromStdErr() ) );
|
||||
connect( fProc, SIGNAL( finished(int, QProcess::ExitStatus) ), this, SLOT( processDone(int, QProcess::ExitStatus) ) );
|
||||
|
||||
fProc->start(program, arguments);
|
||||
if ( !fProc->waitForStarted() ) {
|
||||
// error handling
|
||||
QString msg(tr("Could not execute the output command: ")+cmd[0]);
|
||||
QMessageBox::critical( 0,
|
||||
tr("Fatal error"),
|
||||
msg,
|
||||
tr("Quit") );
|
||||
done(0);
|
||||
}
|
||||
fProcPID = fProc->pid();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Destructor. Checks if the a fit is still running and if yes try to kill it.
|
||||
*/
|
||||
PFitOutputHandler::~PFitOutputHandler()
|
||||
{
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
fProc->terminate();
|
||||
if (!fProc->waitForFinished()) {
|
||||
qDebug() << "fProc still running, will call kill." << endl;
|
||||
fProc->kill();
|
||||
}
|
||||
fProc->waitForFinished();
|
||||
}
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
QString cmd = "kill -9 "+ fProcPID;
|
||||
QString msg = "fProc still running even after Qt kill, will try system kill cmd: "+cmd;
|
||||
qDebug() << msg << endl;
|
||||
system(cmd.toLatin1());
|
||||
}
|
||||
if (fProc) {
|
||||
delete fProc;
|
||||
fProc = 0;
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Captures the standard output and adds it to the output text edit.
|
||||
*/
|
||||
void PFitOutputHandler::readFromStdOut()
|
||||
{
|
||||
// Read and process the data.
|
||||
// Bear in mind that the data might be output in chunks.
|
||||
fOutput->append( fProc->readAllStandardOutput() );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Captures the standard error and adds it to the output text edit.
|
||||
*/
|
||||
void PFitOutputHandler::readFromStdErr()
|
||||
{
|
||||
// Read and process the data.
|
||||
// Bear in mind that the data might be output in chunks.
|
||||
fOutput->append( fProc->readAllStandardError() );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>If musrfit finishes, crashes, ..., the quit button text will be changed to done.
|
||||
*
|
||||
* \param exitCode exit code of musrfit
|
||||
* \param exitStatus exit status of musrfit
|
||||
*/
|
||||
void PFitOutputHandler::processDone(int exitCode, QProcess::ExitStatus exitStatus)
|
||||
{
|
||||
if ((exitStatus == QProcess::CrashExit) && (exitCode != 0))
|
||||
qDebug() << "**ERROR** PFitOutputHandler::processDone: exitCode = " << exitCode << endl;
|
||||
fQuitButton->setText("Done");
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>If the quit button is pressed while the fit is still running, try to terminate musrfit, if this
|
||||
* does not work, try to kill musrfit.
|
||||
*/
|
||||
void PFitOutputHandler::quitButtonPressed()
|
||||
{
|
||||
// if the fitting is still taking place, kill it
|
||||
if (fProc->state() == QProcess::Running) {
|
||||
fProc->terminate();
|
||||
if (!fProc->waitForFinished()) {
|
||||
fProc->kill();
|
||||
}
|
||||
}
|
||||
|
||||
accept();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
73
src/musredit_qt5/PFitOutputHandler.h
Normal file
@ -0,0 +1,73 @@
|
||||
/****************************************************************************
|
||||
|
||||
PFitOutputHandler.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PFITOUTPUTHANDLER_H_
|
||||
#define _PFITOUTPUTHANDLER_H_
|
||||
|
||||
#include <QObject>
|
||||
#include <QProcess>
|
||||
#include <QDialog>
|
||||
#include <QVBoxLayout>
|
||||
#include <QTextEdit>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
#include <QVector>
|
||||
|
||||
#include <cstdlib>
|
||||
|
||||
//---------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This class is the capturing the output of musrfit and displays it in a dialog so
|
||||
* the user has the chance to follow the fitting process, warnings, error messages of
|
||||
* musrfit.
|
||||
*/
|
||||
class PFitOutputHandler : public QDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PFitOutputHandler(QString workingDirectory, QVector<QString> &cmd);
|
||||
virtual ~PFitOutputHandler();
|
||||
|
||||
private slots:
|
||||
virtual void readFromStdOut();
|
||||
virtual void readFromStdErr();
|
||||
virtual void quitButtonPressed();
|
||||
virtual void processDone(int exitCode, QProcess::ExitStatus exitStatus);
|
||||
|
||||
private:
|
||||
Q_PID fProcPID; ///< keeps the process PID
|
||||
QProcess *fProc; ///< pointer to the musrfit process
|
||||
|
||||
QVBoxLayout *fVbox; ///< pointer to the dialog layout manager
|
||||
QTextEdit *fOutput; ///< the captured musrfit output is written (read only) into this text edit object.
|
||||
QPushButton *fQuitButton; ///< quit button, either to interrupt the fit or to close the dialog at the end of the fit.
|
||||
};
|
||||
|
||||
#endif // _PFITOUTPUTHANDLER_H_
|
298
src/musredit_qt5/PGetAsymmetryRunBlockDialog.cpp
Normal file
@ -0,0 +1,298 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetAsymmetryRunBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QComboBox>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PGetAsymmetryRunBlockDialog.h"
|
||||
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url for the asymmetry run block
|
||||
*/
|
||||
PGetAsymmetryRunBlockDialog::PGetAsymmetryRunBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fForwardHistoNo_lineEdit->setValidator( new QIntValidator(fForwardHistoNo_lineEdit) );
|
||||
fBackwardHistoNo_lineEdit->setValidator( new QIntValidator(fBackwardHistoNo_lineEdit) );
|
||||
fDataForwardStart_lineEdit->setValidator( new QIntValidator(fDataForwardStart_lineEdit) );
|
||||
fDataForwardEnd_lineEdit->setValidator( new QIntValidator(fDataForwardEnd_lineEdit) );
|
||||
fDataBackwardStart_lineEdit->setValidator( new QIntValidator(fDataBackwardStart_lineEdit) );
|
||||
fDataBackwardEnd_lineEdit->setValidator( new QIntValidator(fDataBackwardEnd_lineEdit) );
|
||||
fBackgroundForwardStart_lineEdit->setValidator( new QIntValidator(fBackgroundForwardStart_lineEdit) );
|
||||
fBackgroundForwardEnd_lineEdit->setValidator( new QIntValidator(fBackgroundForwardEnd_lineEdit) );
|
||||
fBackgroundBackwardStart_lineEdit->setValidator( new QIntValidator(fBackgroundBackwardStart_lineEdit) );
|
||||
fBackgroundBackwardEnd_lineEdit->setValidator( new QIntValidator(fBackgroundBackwardEnd_lineEdit) );
|
||||
fBackgroundForwardFix_lineEdit->setValidator( new QDoubleValidator(fBackgroundForwardFix_lineEdit) );
|
||||
fBackgroundBackwardFix_lineEdit->setValidator( new QDoubleValidator(fBackgroundBackwardFix_lineEdit) );
|
||||
fFitRangeStart_lineEdit->setValidator( new QDoubleValidator(fFitRangeStart_lineEdit) );
|
||||
fFitRangeEnd_lineEdit->setValidator( new QDoubleValidator(fFitRangeEnd_lineEdit) );
|
||||
fPacking_lineEdit->setValidator( new QIntValidator(fPacking_lineEdit) );
|
||||
fAlpha_lineEdit->setValidator( new QIntValidator(fAlpha_lineEdit) );
|
||||
fBeta_lineEdit->setValidator( new QIntValidator(fBeta_lineEdit) );
|
||||
fT0Forward_lineEdit->setValidator( new QIntValidator(fT0Forward_lineEdit) );
|
||||
fT0Backward_lineEdit->setValidator( new QIntValidator(fT0Backward_lineEdit) );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the run information line of the asymmetry run block.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getRunHeaderInfo()
|
||||
{
|
||||
QString str;
|
||||
|
||||
str = "RUN " + fRunFileName_lineEdit->text() + " ";
|
||||
str += fBeamline_lineEdit->text().toUpper() + " ";
|
||||
str += fInstitute_comboBox->currentText() + " ";
|
||||
str += fFileFormat_comboBox->currentText() + " (name beamline institute data-file-format)\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the alpha parameter for the asymmetry run block.
|
||||
*
|
||||
* \param present flag indicating if the alpha parameter is used, or a default alpha==1 is going to be used.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getAlphaParameter(bool &present)
|
||||
{
|
||||
QString str = "alpha " + fAlpha_lineEdit->text() + "\n";
|
||||
|
||||
if (str.isEmpty())
|
||||
present = false;
|
||||
else
|
||||
present = true;
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the beta parameter for the asymmetry run block
|
||||
*
|
||||
* \param present flag indicating if the beta parameter is used, or a default beta==1 is going to be used.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getBetaParameter(bool &present)
|
||||
{
|
||||
QString str = "beta " + fBeta_lineEdit->text() + "\n";
|
||||
|
||||
if (str.isEmpty())
|
||||
present = false;
|
||||
else
|
||||
present = true;
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the map for the asymmetry run block.
|
||||
*
|
||||
* \param valid flag indicating if the map is potentially valid.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getMap(bool &valid)
|
||||
{
|
||||
QString str = fMap_lineEdit->text().trimmed().remove(" ");
|
||||
|
||||
// check if potentially proper map line
|
||||
for (int i=0; i<str.length(); i++) {
|
||||
if (!str[i].isDigit()) {
|
||||
valid = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
str = "map " + fMap_lineEdit->text() + "\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the background information for the asymmetry run block.
|
||||
*
|
||||
* \param valid flag indicating if a valid background (either backgr.fix or background is given, but not both)
|
||||
* is present.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getBackground(bool &valid)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
valid = true;
|
||||
|
||||
// check that either backgr.fix or background is given, but not both
|
||||
if (fBackgroundForwardStart_lineEdit->text().isEmpty() && fBackgroundForwardEnd_lineEdit->text().isEmpty() &&
|
||||
fBackgroundBackwardStart_lineEdit->text().isEmpty() && fBackgroundBackwardEnd_lineEdit->text().isEmpty() &&
|
||||
fBackgroundForwardFix_lineEdit->text().isEmpty() && fBackgroundBackwardFix_lineEdit->text().isEmpty()) {
|
||||
valid = false;
|
||||
str = "background 0 10 0 10\n";
|
||||
} else {
|
||||
if (!fBackgroundForwardStart_lineEdit->text().isEmpty()) { // assume the rest is given, not fool prove but ...
|
||||
str = "background ";
|
||||
str += fBackgroundForwardStart_lineEdit->text() + " ";
|
||||
str += fBackgroundForwardEnd_lineEdit->text() + " ";
|
||||
str += fBackgroundBackwardStart_lineEdit->text() + " ";
|
||||
str += fBackgroundBackwardEnd_lineEdit->text() + "\n";
|
||||
}
|
||||
if (!fBackgroundForwardFix_lineEdit->text().isEmpty()) { // assume the rest is given, not fool prove but ...
|
||||
str = "backgr.fix ";
|
||||
str += fBackgroundForwardFix_lineEdit->text() + " ";
|
||||
str += fBackgroundBackwardFix_lineEdit->text() + "\n";
|
||||
}
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a data range (in bins) entry for the asymmetry run block.
|
||||
*
|
||||
* \param valid flag indicating if the data entries are valid.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getData(bool &valid)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (fDataForwardStart_lineEdit->text().isEmpty() || fDataForwardEnd_lineEdit->text().isEmpty() ||
|
||||
fDataBackwardStart_lineEdit->text().isEmpty() || fDataBackwardEnd_lineEdit->text().isEmpty()) {
|
||||
valid = false;
|
||||
} else {
|
||||
str = "data ";
|
||||
str += fDataForwardStart_lineEdit->text() + " ";
|
||||
str += fDataForwardEnd_lineEdit->text() + " ";
|
||||
str += fDataBackwardStart_lineEdit->text() + " ";
|
||||
str += fDataBackwardEnd_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a t0 parameter for the asymmetry run block.
|
||||
*
|
||||
* \param present flag indicating if a t0 parameter is set.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getT0(bool &present)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (!fT0Forward_lineEdit->text().isEmpty() && !fT0Forward_lineEdit->text().isEmpty()) {
|
||||
str = "t0 ";
|
||||
str += fT0Forward_lineEdit->text() + " ";
|
||||
str += fT0Backward_lineEdit->text() + "\n";
|
||||
present = true;
|
||||
} else {
|
||||
present = false;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a fit range entry for the asymmetry run block. If no fit range has been provided,
|
||||
* a fit range [0,10] will be set and the valid flag will be set to false.
|
||||
*
|
||||
* \param valid flag indicating if a fit range was provided.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getFitRange(bool &valid)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (fFitRangeStart_lineEdit->text().isEmpty() || fFitRangeEnd_lineEdit->text().isEmpty()) {
|
||||
str += "fit 0.0 10.0\n";
|
||||
valid = false;
|
||||
} else {
|
||||
str += "fit ";
|
||||
str += fFitRangeStart_lineEdit->text() + " ";
|
||||
str += fFitRangeEnd_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the packing/binning of the asymmetry run block. If no packing has been provided,
|
||||
* a packing of '1' will be set and the present flag will be set to false.
|
||||
*
|
||||
* \param present flag indicating if a packing parameter was provided.
|
||||
*/
|
||||
QString PGetAsymmetryRunBlockDialog::getPacking(bool &present)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (fPacking_lineEdit->text().isEmpty()) {
|
||||
present = false;
|
||||
str += "packing 1\n";
|
||||
} else {
|
||||
present = true;
|
||||
str += "packing " + fPacking_lineEdit->text() + "\n\n";
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the asymmetry run block.
|
||||
*/
|
||||
void PGetAsymmetryRunBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
65
src/musredit_qt5/PGetAsymmetryRunBlockDialog.h
Normal file
@ -0,0 +1,65 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetAsymmetryRunBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETASYMMETRYRUNBLOCKDIALOG_H_
|
||||
#define _PGETASYMMETRYRUNBLOCKDIALOG_H_
|
||||
|
||||
#include "ui_PGetAsymmetryRunBlockDialog.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class handling the content of the menu: Edit/Add Block/Asymmetry Run Block.
|
||||
*/
|
||||
class PGetAsymmetryRunBlockDialog : public QDialog, private Ui::PGetAsymmetryRunBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetAsymmetryRunBlockDialog(const QString helpUrl);
|
||||
|
||||
QString getRunHeaderInfo();
|
||||
QString getAlphaParameter(bool &present);
|
||||
QString getBetaParameter(bool &present);
|
||||
QString getMap(bool &valid);
|
||||
QString getForward() { return QString("forward " + fForwardHistoNo_lineEdit->text() + "\n"); }
|
||||
QString getBackward() { return QString("backward " + fBackwardHistoNo_lineEdit->text() + "\n"); }
|
||||
QString getBackground(bool &valid);
|
||||
QString getData(bool &valid);
|
||||
QString getT0(bool &present);
|
||||
QString getFitRange(bool &valid);
|
||||
QString getPacking(bool &present);
|
||||
|
||||
private slots:
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url for the asymmetry run block
|
||||
};
|
||||
|
||||
#endif // _PGETASYMMETRYRUNBLOCKDIALOG_H_
|
118
src/musredit_qt5/PGetDefaultDialog.cpp
Normal file
@ -0,0 +1,118 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetDefaultDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QObject>
|
||||
#include <QComboBox>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PGetDefaultDialog.h"
|
||||
|
||||
#define INSTITUTE_PSI 0
|
||||
#define INSTITUTE_RAL 1
|
||||
#define INSTITUTE_TRIUMF 2
|
||||
#define INSTITUTE_JPARC 3
|
||||
|
||||
#define FILE_FORMAT_NEXUS 0
|
||||
#define FILE_FORMAT_ROOT_NPP 1
|
||||
#define FILE_FORMAT_ROOT_PPC 2
|
||||
#define FILE_FORMAT_PSIBIN 3
|
||||
#define FILE_FORMAT_MUD 4
|
||||
#define FILE_FORMAT_WKM 5
|
||||
#define FILE_FORMAT_ASCII 6
|
||||
#define FILE_FORMAT_DB 7
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor
|
||||
*
|
||||
* \param helpUrl help url for the default dialog
|
||||
*/
|
||||
PGetDefaultDialog::PGetDefaultDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Finds the name of the institute in the combo box and selects it.
|
||||
*
|
||||
* \param str name of the institute
|
||||
*/
|
||||
void PGetDefaultDialog::setInstitute(const QString &str) {
|
||||
|
||||
for (int i=0; i<fInstitute_comboBox->count(); i++) {
|
||||
if (fInstitute_comboBox->itemText(i).toLower() == str.toLower()) {
|
||||
fInstitute_comboBox->setCurrentIndex(i);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Finds the file format in the combo box and selects it.
|
||||
*
|
||||
* \param str file format
|
||||
*/
|
||||
void PGetDefaultDialog::setFileFormat(const QString &str)
|
||||
{
|
||||
|
||||
for (int i=0; i<fFileFormat_comboBox->count(); i++) {
|
||||
if (fFileFormat_comboBox->itemText(i).toLower() == str.toLower()) {
|
||||
fFileFormat_comboBox->setCurrentIndex(i);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description fitting the default dialog.
|
||||
*/
|
||||
void PGetDefaultDialog::helpContent()
|
||||
{
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
// END
|
||||
//---------------------------------------------------------------------------
|
69
src/musredit_qt5/PGetDefaultDialog.h
Normal file
@ -0,0 +1,69 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetDefaultDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETDEFAULTDIALOG_H_
|
||||
#define _PGETDEFAULTDIALOG_H_
|
||||
|
||||
#include <QString>
|
||||
#include <QWidget>
|
||||
#include <QLineEdit>
|
||||
#include <QComboBox>
|
||||
|
||||
#include "ui_PGetDefaultDialog.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handels the default dialog which is used to generate a default asymmetry or
|
||||
* single histogram msr input file.
|
||||
*/
|
||||
class PGetDefaultDialog : public QDialog, private Ui::PGetDefaultDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetDefaultDialog(const QString helpUrl = "");
|
||||
virtual ~PGetDefaultDialog() {}
|
||||
|
||||
virtual const QString getRunFileName() const { return fRunFileName_lineEdit->text(); }
|
||||
virtual const QString getBeamline() const { return fBeamline_lineEdit->text(); }
|
||||
virtual const QString getInstitute() const { return fInstitute_comboBox->currentText(); }
|
||||
virtual const QString getFileFormat() const { return fFileFormat_comboBox->currentText(); }
|
||||
|
||||
virtual void setBeamline(const QString &str) { fBeamline_lineEdit->setText(str); }
|
||||
virtual void setInstitute(const QString &str);
|
||||
virtual void setFileFormat(const QString &str);
|
||||
|
||||
protected slots:
|
||||
virtual void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url for the default dialog
|
||||
};
|
||||
|
||||
#endif // _PGETDEFAULTDIALOG_H_
|
146
src/musredit_qt5/PGetFourierBlockDialog.cpp
Normal file
@ -0,0 +1,146 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetFourierBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QObject>
|
||||
#include <QComboBox>
|
||||
#include <QValidator>
|
||||
#include <QLineEdit>
|
||||
#include <QPushButton>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PGetFourierBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor
|
||||
*
|
||||
* \param helpUrl help url address for the Fourier block.
|
||||
*/
|
||||
PGetFourierBlockDialog::PGetFourierBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fFourierBlock = "";
|
||||
fFourierPower_lineEdit->setValidator( new QIntValidator(fFourierPower_lineEdit) );
|
||||
fPhaseCorrectionRangeLow_lineEdit->setValidator( new QDoubleValidator(fPhaseCorrectionRangeLow_lineEdit) );
|
||||
fPhaseCorrectionRangeUp_lineEdit->setValidator( new QDoubleValidator(fPhaseCorrectionRangeUp_lineEdit) );
|
||||
fRangeLow_lineEdit->setValidator( new QDoubleValidator(fRangeLow_lineEdit) );
|
||||
fRangeUp_lineEdit->setValidator( new QDoubleValidator(fRangeUp_lineEdit) );
|
||||
|
||||
connect( fPhase_lineEdit, SIGNAL( lostFocus() ), this, SLOT( checkPhaseParameter() ) );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Checks if the phase parameter is either a number are has the form parXX, where XX is a number.
|
||||
*/
|
||||
void PGetFourierBlockDialog::checkPhaseParameter()
|
||||
{
|
||||
QString str = fPhase_lineEdit->text();
|
||||
|
||||
if (str.isEmpty())
|
||||
return;
|
||||
|
||||
bool ok;
|
||||
int ival;
|
||||
|
||||
ival = str.toInt(&ok);
|
||||
if (!ok) { // i.e. the phase entry is not a number. Check for parXX
|
||||
str.trimmed();
|
||||
if (str.startsWith("par")) { //
|
||||
str.remove("par");
|
||||
ival = str.toInt(&ok);
|
||||
if (!ok) {
|
||||
fPhase_lineEdit->clear();
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Allowed phase entries are either a parameter number,\n or an parXX entry, where XX is a parameter number",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
fPhase_lineEdit->setFocus();
|
||||
}
|
||||
} else { // neither a parXX nor a number
|
||||
fPhase_lineEdit->clear();
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Allowed phase entries are either a parameter number,\n or an parXX entry, where XX is a parameter number",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
fPhase_lineEdit->setFocus();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Transfers the data of the dialog into a valid msr-file Fourier block string.
|
||||
*/
|
||||
void PGetFourierBlockDialog::fillFourierBlock()
|
||||
{
|
||||
fFourierBlock = "###############################################################\n";
|
||||
fFourierBlock += "FOURIER\n";
|
||||
fFourierBlock += "units " + fUnits_comboBox->currentText() + "\n";
|
||||
QString str = fFourierPower_lineEdit->text();
|
||||
if (!str.isEmpty())
|
||||
fFourierBlock += "fourier_power " + str + "\n";
|
||||
fFourierBlock += "apodization " + fApodization_comboBox->currentText() + "\n";
|
||||
fFourierBlock += "plot " + fPlot_comboBox->currentText() + "\n";
|
||||
str = fPhase_lineEdit->text();
|
||||
if (!str.isEmpty())
|
||||
fFourierBlock += "phase " + str + "\n";
|
||||
if (!fPhaseCorrectionRangeLow_lineEdit->text().isEmpty() && !fPhaseCorrectionRangeUp_lineEdit->text().isEmpty()) {
|
||||
fFourierBlock += "range_for_phase_correction " + fPhaseCorrectionRangeLow_lineEdit->text() + " " +
|
||||
fPhaseCorrectionRangeUp_lineEdit->text() + "\n";
|
||||
}
|
||||
if (!fRangeLow_lineEdit->text().isEmpty() && !fRangeUp_lineEdit->text().isEmpty()) {
|
||||
fFourierBlock += "range " + fRangeLow_lineEdit->text() + " " + fRangeUp_lineEdit->text() + "\n";
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the Fourier block.
|
||||
*/
|
||||
void PGetFourierBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
60
src/musredit_qt5/PGetFourierBlockDialog.h
Normal file
@ -0,0 +1,60 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetFourierBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETFOURIERBLOCKDIALOG_H_
|
||||
#define _PGETFOURIERBLOCKDIALOG_H_
|
||||
|
||||
#include <QString>
|
||||
|
||||
#include "ui_PGetFourierBlockDialog.h"
|
||||
|
||||
//-------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handles the Fourier dialog.
|
||||
*/
|
||||
class PGetFourierBlockDialog : public QDialog, private Ui::PGetFourierBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetFourierBlockDialog(const QString helpUrl);
|
||||
|
||||
QString getFourierBlock() { return fFourierBlock; }
|
||||
|
||||
private slots:
|
||||
void checkPhaseParameter();
|
||||
void fillFourierBlock();
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fFourierBlock; ///< keeps the msr Fourier block
|
||||
QString fHelpUrl; ///< help url for the Fourier block
|
||||
};
|
||||
|
||||
#endif // _PGETFOURIERBLOCKDIALOG_H_
|
122
src/musredit_qt5/PGetFunctionsBlockDialog.cpp
Normal file
@ -0,0 +1,122 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetFunctionsBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QTextEdit>
|
||||
#include <QLineEdit>
|
||||
#include <QMessageBox>
|
||||
#include <QRegExp>
|
||||
#include <QEvent>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PGetFunctionsBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url for the FUNCTIONS block.
|
||||
*/
|
||||
PGetFunctionsBlockDialog::PGetFunctionsBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fFunctionInput_lineEdit->setFocus();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Adds a function to the FUNCTIONS block text edit after carrying out some primitve tests about
|
||||
* the consistency of the function (far from being a syntax/semantic checker!!).
|
||||
*/
|
||||
void PGetFunctionsBlockDialog::addFunction()
|
||||
{
|
||||
QString str = fFunctionInput_lineEdit->text();
|
||||
|
||||
if (str.isEmpty())
|
||||
return;
|
||||
|
||||
// validation
|
||||
|
||||
// check that the function string starts with 'fun'
|
||||
if (!str.trimmed().startsWith("fun")) {
|
||||
QMessageBox::critical(this, "addFunction",
|
||||
"a function has to start with 'funX' (X a number).\nNeeds to be fixed.",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
}
|
||||
|
||||
// check if function string contains 'funX ='
|
||||
if (str.indexOf( QRegExp("fun\\d+\\s*=") ) == -1) {
|
||||
QMessageBox::critical(this, "addFunction",
|
||||
"a function has to start with 'funX =' (X a positive number).\nNeeds to be fixed.",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
}
|
||||
|
||||
// check if function string contains more than one 'funX'
|
||||
if (str.trimmed().lastIndexOf("fun", -1, Qt::CaseInsensitive) > 0) {
|
||||
QMessageBox::critical(this, "addFunction",
|
||||
"a function cannot contain more than one function,\ni.e. fun2 = fun1 + par1 is not OK.",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
}
|
||||
|
||||
// add to Functions block
|
||||
fFunctionBlock_plainTextEdit->appendPlainText(str);
|
||||
|
||||
// clear functions input text
|
||||
fFunctionInput_lineEdit->clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the FUNCTIONS block.
|
||||
*/
|
||||
void PGetFunctionsBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
56
src/musredit_qt5/PGetFunctionsBlockDialog.h
Normal file
@ -0,0 +1,56 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetFunctionsBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETFUNCTIONSBLOCKDIALOG_H_
|
||||
#define _PGETFUNCTIONSBLOCKDIALOG_H_
|
||||
|
||||
#include "ui_PGetFunctionsBlockDialog.h"
|
||||
|
||||
//-----------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handles the content of the FUNCTIONS block dialog.
|
||||
*/
|
||||
class PGetFunctionsBlockDialog : public QDialog, private Ui::PGetFunctionsBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetFunctionsBlockDialog(const QString helpUrl = "");
|
||||
|
||||
QString getFunctionsBlock() { return fFunctionBlock_plainTextEdit->toPlainText(); }
|
||||
|
||||
private slots:
|
||||
void addFunction();
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url address for the FUNCTIONS block.
|
||||
};
|
||||
|
||||
#endif // _PGETFUNCTIONSBLOCKDIALOG_H_
|
596
src/musredit_qt5/PGetMusrFTOptionsDialog.cpp
Normal file
@ -0,0 +1,596 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetMusrFTOptionsDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2015 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QComboBox>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PGetMusrFTOptionsDialog.h"
|
||||
|
||||
#define MUSRFT_OPT_UNDEF 0
|
||||
#define MUSRFT_OPT_REAL 1
|
||||
#define MUSRFT_OPT_IMAG 2
|
||||
#define MUSRFT_OPT_REAL_AND_IMAG 3
|
||||
#define MUSRFT_OPT_POWER 4
|
||||
#define MUSRFT_OPT_PHASE 5
|
||||
|
||||
#define MUSRFT_APOD_UNDEF 0
|
||||
#define MUSRFT_APOD_WEAK 1
|
||||
#define MUSRFT_APOD_MEDIUM 2
|
||||
#define MUSRFT_APOD_STRONG 3
|
||||
|
||||
#define MUSRFT_UNIT_UNDEF 0
|
||||
#define MUSRFT_UNIT_GAUSS 1
|
||||
#define MUSRFT_UNIT_TESLA 2
|
||||
#define MUSRFT_UNIT_FREQ 3
|
||||
#define MUSRFT_UNIT_CYCLE 4
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param currentMsrFile path-file name of the currently active msr-file in musredit
|
||||
* \param prevCmd list of the last (potential) previously call.
|
||||
* \param helpUrl help url for the asymmetry run block
|
||||
*/
|
||||
PGetMusrFTOptionsDialog::PGetMusrFTOptionsDialog(QString currentMsrFile, QStringList &prevCmd, const QString helpUrl) :
|
||||
fCurrentMsrFileName(currentMsrFile), fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
setModal(true);
|
||||
|
||||
fBkgRangeStartBin_lineEdit->setValidator( new QIntValidator(fBkgRangeStartBin_lineEdit) );
|
||||
fBkgRangeEndBin_lineEdit->setValidator( new QIntValidator(fBkgRangeEndBin_lineEdit) );
|
||||
fPacking_lineEdit->setValidator( new QIntValidator(fPacking_lineEdit) );
|
||||
fTimeRangeStart_lineEdit->setValidator( new QDoubleValidator(fTimeRangeStart_lineEdit) );
|
||||
fTimeRangeEnd_lineEdit->setValidator( new QDoubleValidator(fTimeRangeEnd_lineEdit) );
|
||||
fFourierPower_lineEdit->setValidator( new QIntValidator(fFourierPower_lineEdit) );
|
||||
fLifetimeCorrection_lineEdit->setValidator( new QDoubleValidator(fLifetimeCorrection_lineEdit) );
|
||||
fFourierRangeStart_lineEdit->setValidator( new QDoubleValidator(fFourierRangeStart_lineEdit) );
|
||||
fFourierRangeEnd_lineEdit->setValidator( new QDoubleValidator(fFourierRangeEnd_lineEdit) );
|
||||
fPacking_lineEdit->setText("1");
|
||||
|
||||
// populate dialog with the previous cmd call
|
||||
bool msrTag = true;
|
||||
QString str, str1, line;
|
||||
int idx;
|
||||
for (int i=0; i<prevCmd.size(); i++) {
|
||||
// collect msr-file-names
|
||||
if (msrTag) {
|
||||
line = "";
|
||||
while (prevCmd[i].contains(".msr") && (i<prevCmd.size())) {
|
||||
// split msr-file path-name into path and name
|
||||
str = prevCmd[i];
|
||||
idx = str.lastIndexOf("/");
|
||||
str1 = str;
|
||||
str.remove(idx, str.length()-idx);
|
||||
fMsrFilePaths << str;
|
||||
str1.remove(0, idx+1);
|
||||
fMsrFileNames << str1;
|
||||
line += str1 + " ";
|
||||
i++;
|
||||
}
|
||||
line.remove(line.length()-1, 1);
|
||||
fMsrFileSelector_lineEdit->setText(line);
|
||||
msrTag = false;
|
||||
}
|
||||
// collect data-file-names
|
||||
if (prevCmd[i] == "-df") {
|
||||
i++;
|
||||
line = "";
|
||||
while (!prevCmd[i].startsWith("-") && (i<prevCmd.size())) {
|
||||
// split msr-file path-name into path and name
|
||||
str = prevCmd[i];
|
||||
idx = str.lastIndexOf("/");
|
||||
str1 = str;
|
||||
str.remove(idx, str.length()-idx);
|
||||
fDataFilePaths << str;
|
||||
str1.remove(0, idx+1);
|
||||
fDataFileNames << str1;
|
||||
line += str1 + " ";
|
||||
i++;
|
||||
}
|
||||
line.remove(line.length()-1, 1);
|
||||
fDataFileSelector_lineEdit->setText(line);
|
||||
}
|
||||
// background-range
|
||||
if (prevCmd[i] == "-br") {
|
||||
fBkgRangeStartBin_lineEdit->setText(prevCmd[++i]);
|
||||
fBkgRangeEndBin_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
// fourier-option
|
||||
if (prevCmd[i] == "-fo") {
|
||||
if (prevCmd[i+1] == "real")
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_REAL);
|
||||
else if (prevCmd[i+1] == "imag")
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_IMAG);
|
||||
else if (prevCmd[i+1] == "real+imag")
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_REAL_AND_IMAG);
|
||||
else if (prevCmd[i+1] == "power")
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_POWER);
|
||||
else if (prevCmd[i+1] == "phase")
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_PHASE);
|
||||
else
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_UNDEF);
|
||||
i++;
|
||||
}
|
||||
// apodization
|
||||
if (prevCmd[i] == "-ap") {
|
||||
if (prevCmd[i+1] == "weak")
|
||||
fApodization_comboBox->setCurrentIndex(MUSRFT_APOD_WEAK);
|
||||
else if (prevCmd[i+1] == "medium")
|
||||
fApodization_comboBox->setCurrentIndex(MUSRFT_APOD_MEDIUM);
|
||||
else if (prevCmd[i+1] == "strong")
|
||||
fApodization_comboBox->setCurrentIndex(MUSRFT_APOD_STRONG);
|
||||
else
|
||||
fApodization_comboBox->setCurrentIndex(MUSRFT_APOD_UNDEF);
|
||||
i++;
|
||||
}
|
||||
// fourier-power
|
||||
if (prevCmd[i] == "-fp") {
|
||||
fFourierPower_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
// units
|
||||
if (prevCmd[i] == "-u") {
|
||||
if (prevCmd[i+1] == "Gauss")
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_GAUSS);
|
||||
else if (prevCmd[i+1] == "Tesla")
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_TESLA);
|
||||
else if (prevCmd[i+1] == "MHz")
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_FREQ);
|
||||
else if (prevCmd[i+1] == "Mc/s")
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_CYCLE);
|
||||
else
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_UNDEF);
|
||||
i++;
|
||||
}
|
||||
// phase
|
||||
if (prevCmd[i] == "-ph") {
|
||||
// NOT YET IMPLEMENTED
|
||||
}
|
||||
// fourier-range
|
||||
if (prevCmd[i] == "-fr") {
|
||||
fFourierRangeStart_lineEdit->setText(prevCmd[++i]);
|
||||
fFourierRangeEnd_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
// time-range
|
||||
if (prevCmd[i] == "-tr") {
|
||||
fTimeRangeStart_lineEdit->setText(prevCmd[++i]);
|
||||
fTimeRangeEnd_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
// histo list
|
||||
if (prevCmd[i] == "--histo") {
|
||||
i++;
|
||||
line = "";
|
||||
while (!prevCmd[i].startsWith("-") && (i<prevCmd.size())) {
|
||||
line += prevCmd[i++] + " ";
|
||||
}
|
||||
line.remove(line.length()-1, 1);
|
||||
fHistoList_lineEdit->setText(line);
|
||||
}
|
||||
// average ALL tag
|
||||
if (prevCmd[i] == "-a") {
|
||||
fAveragedView_checkBox->setCheckState(Qt::Checked);
|
||||
}
|
||||
// average per data set tag
|
||||
if (prevCmd[i] == "-ad") {
|
||||
fAveragePerDataSet_checkBox->setCheckState(Qt::Checked);
|
||||
}
|
||||
// t0 list
|
||||
if (prevCmd[i] == "--t0") {
|
||||
i++;
|
||||
line = "";
|
||||
while (!prevCmd[i].startsWith("-") && (i<prevCmd.size())) {
|
||||
line += prevCmd[i++] + " ";
|
||||
}
|
||||
line.remove(line.length()-1, 1);
|
||||
fT0_lineEdit->setText(line);
|
||||
}
|
||||
// packing
|
||||
if (prevCmd[i] == "-pa") {
|
||||
fPacking_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
// title
|
||||
if (prevCmd[i] == "--title") {
|
||||
fFourierTitle_lineEdit->setText(prevCmd[i+1]);
|
||||
}
|
||||
// create msr-file tag
|
||||
if (prevCmd[i] == "--create-msr-file") {
|
||||
fCreateMsrFileName = prevCmd[++i];
|
||||
fCreateMsrFile_checkBox->setCheckState(Qt::Checked);
|
||||
}
|
||||
// lifetime correction
|
||||
if (prevCmd[i] == "-lc") {
|
||||
fLifetimeCorrection_lineEdit->setText(prevCmd[++i]);
|
||||
}
|
||||
}
|
||||
|
||||
// connect all necessary single and slots
|
||||
connect(fCurrentMsrFile_checkBox, SIGNAL( stateChanged(int) ), this, SLOT( currentMsrFileTagChanged(int) ) );
|
||||
connect(fAllMsrFiles_checkBox, SIGNAL( stateChanged(int) ), this, SLOT( allMsrFileTagChanged(int) ) );
|
||||
connect(fMsrFileSelector_pushButton, SIGNAL( clicked() ), this, SLOT( selectMsrFileNames() ) );
|
||||
connect(fDataFileSelector_pushButton, SIGNAL( clicked() ), this, SLOT( selectDataFileNames() ) );
|
||||
connect(fCreateMsrFile_checkBox, SIGNAL( stateChanged(int) ), this, SLOT( createMsrFileChanged(int) ) );
|
||||
connect(fMsrFileNameClear_pushButton, SIGNAL (clicked() ), this, SLOT( clearMsrFileNames() ) );
|
||||
connect(fDataFileNameClear_pushButton, SIGNAL (clicked() ), this, SLOT( clearDataFileNames() ) );
|
||||
connect(fResetAll_pushButton, SIGNAL( clicked() ), this, SLOT( resetAll() ) );
|
||||
connect(fAveragedView_checkBox, SIGNAL ( stateChanged(int) ), this, SLOT( averagedAll(int) ) );
|
||||
connect(fAveragePerDataSet_checkBox, SIGNAL ( stateChanged(int) ), this, SLOT( averagedPerDataSet(int) ) );
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the musrFT command line options.
|
||||
*/
|
||||
QStringList PGetMusrFTOptionsDialog::getMusrFTOptions()
|
||||
{
|
||||
QStringList cmd;
|
||||
QString str("");
|
||||
QStringList strList;
|
||||
|
||||
// check if currently active msr-file shall be used
|
||||
if (fCurrentMsrFile_checkBox->checkState() == Qt::Checked) {
|
||||
cmd << fCurrentMsrFileName;
|
||||
} else {
|
||||
// msr-files
|
||||
for (int i=0; i<fMsrFilePaths.size(); i++) {
|
||||
str = fMsrFilePaths[i]+"/"+fMsrFileNames[i];
|
||||
cmd << str;
|
||||
}
|
||||
|
||||
// data-files
|
||||
if (fDataFilePaths.size() > 0) {
|
||||
cmd << "-df";
|
||||
for (int i=0; i<fDataFilePaths.size(); i++) {
|
||||
str = fDataFilePaths[i]+"/"+fDataFileNames[i];
|
||||
cmd << str;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// background range
|
||||
if ((fBkgRangeStartBin_lineEdit->text().length() > 0) && (fBkgRangeEndBin_lineEdit->text().length() > 0)) {
|
||||
cmd << "-br";
|
||||
cmd << fBkgRangeStartBin_lineEdit->text();
|
||||
cmd << fBkgRangeEndBin_lineEdit->text();
|
||||
}
|
||||
|
||||
// background values
|
||||
if (fBkgList_lineEdit->text().length() > 0) {
|
||||
|
||||
}
|
||||
|
||||
// fourier-option
|
||||
if (fFourierOption_comboBox->currentText() != "UnDef") {
|
||||
cmd << "-fo";
|
||||
cmd << fFourierOption_comboBox->currentText();
|
||||
}
|
||||
|
||||
// apodization
|
||||
cmd << "-ap";
|
||||
cmd << fApodization_comboBox->currentText();
|
||||
|
||||
// fourier-power
|
||||
if (fFourierPower_lineEdit->text().length() > 0) {
|
||||
cmd << "-fp";
|
||||
cmd << fFourierPower_lineEdit->text();
|
||||
}
|
||||
|
||||
// units
|
||||
if (fFourierUnits_comboBox->currentText() != "UnDef") {
|
||||
cmd << "-u";
|
||||
cmd << fFourierUnits_comboBox->currentText();
|
||||
}
|
||||
|
||||
// phase
|
||||
|
||||
// fourier-range
|
||||
if ((fFourierRangeStart_lineEdit->text().length() > 0) && (fFourierRangeEnd_lineEdit->text().length() > 0)) {
|
||||
cmd << "-fr";
|
||||
cmd << fFourierRangeStart_lineEdit->text();
|
||||
cmd << fFourierRangeEnd_lineEdit->text();
|
||||
}
|
||||
|
||||
// time-range
|
||||
if ((fTimeRangeStart_lineEdit->text().length() > 0) && (fTimeRangeEnd_lineEdit->text().length() > 0)) {
|
||||
cmd << "-tr";
|
||||
cmd << fTimeRangeStart_lineEdit->text();
|
||||
cmd << fTimeRangeEnd_lineEdit->text();
|
||||
}
|
||||
|
||||
// histo list
|
||||
if (fHistoList_lineEdit->text().length() > 0) {
|
||||
cmd << "--histo";
|
||||
strList = fHistoList_lineEdit->text().split(" ", QString::SkipEmptyParts);
|
||||
for (int i=0; i<strList.size(); i++)
|
||||
cmd << strList[i];
|
||||
}
|
||||
|
||||
// averaged view ALL
|
||||
if (fAveragedView_checkBox->checkState() == Qt::Checked)
|
||||
cmd << "-a";
|
||||
|
||||
// averaged view per data set
|
||||
if (fAveragePerDataSet_checkBox->checkState() == Qt::Checked)
|
||||
cmd << "-ad";
|
||||
|
||||
// t0 list
|
||||
if (fT0_lineEdit->text().length() > 0) {
|
||||
cmd << "--t0";
|
||||
strList = fT0_lineEdit->text().split(" ", QString::SkipEmptyParts);
|
||||
for (int i=0; i<strList.size(); i++)
|
||||
cmd << strList[i];
|
||||
}
|
||||
|
||||
// packing
|
||||
if (fPacking_lineEdit->text().length() > 0) {
|
||||
cmd << "-pa";
|
||||
cmd << fPacking_lineEdit->text();
|
||||
}
|
||||
|
||||
// title
|
||||
if (fFourierTitle_lineEdit->text().length() > 0) {
|
||||
cmd << "--title";
|
||||
cmd << fFourierTitle_lineEdit->text();
|
||||
}
|
||||
|
||||
// create-msr-file
|
||||
if (fCreateMsrFile_checkBox->checkState() == Qt::Checked) {
|
||||
cmd << "--create-msr-file";
|
||||
cmd << fCreateMsrFileName;
|
||||
}
|
||||
|
||||
// lifetimecorrection
|
||||
if (fLifetimeCorrection_lineEdit->text().length() > 0) {
|
||||
cmd << "-lc";
|
||||
cmd << fLifetimeCorrection_lineEdit->text();
|
||||
}
|
||||
|
||||
return cmd;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when fCurrentMsrFile_checkBox is checked/unchecked. If checked, it will clean up
|
||||
* the msr-file path-file list and the data-file path-file list.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::currentMsrFileTagChanged(int state)
|
||||
{
|
||||
if (state == Qt::Checked) {
|
||||
fAllMsrFiles_checkBox->setCheckState(Qt::Unchecked);
|
||||
|
||||
// remove all msr-data-file-names and data-path-file-names
|
||||
fMsrFilePaths.clear();
|
||||
fMsrFileNames.clear();
|
||||
fMsrFileSelector_lineEdit->setText("");
|
||||
fDataFilePaths.clear();
|
||||
fDataFileNames.clear();
|
||||
fDataFileSelector_lineEdit->setText("");
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when fAllMsrFiles_checkBox is checked/unchecked. Currently it has no functionality.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::allMsrFileTagChanged(int state)
|
||||
{
|
||||
if (state == Qt::Checked) {
|
||||
fCurrentMsrFile_checkBox->setCheckState(Qt::Unchecked);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when fMsrFileSelector_pushButton is clicked. Collects the msr-file path-name list.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::selectMsrFileNames()
|
||||
{
|
||||
QStringList flns = QFileDialog::getOpenFileNames( this, tr("Open msr-File(s)"), tr( "./" ),
|
||||
tr( "msr-Files (*.msr);;All Files (*)" ));
|
||||
|
||||
QString str(""), str1("");
|
||||
int idx;
|
||||
if (flns.size() > 0) {
|
||||
// delete already present elements
|
||||
fMsrFilePaths.clear();
|
||||
fMsrFileNames.clear();
|
||||
|
||||
// split path-name into path and name
|
||||
for (int i=0; i<flns.size(); i++) {
|
||||
str = flns[i];
|
||||
idx = str.lastIndexOf("/");
|
||||
str1 = str;
|
||||
str.remove(idx, str.length()-idx);
|
||||
fMsrFilePaths << str;
|
||||
str1.remove(0, idx+1);
|
||||
fMsrFileNames << str1;
|
||||
}
|
||||
|
||||
// populate fMsrFileSelector_lineEdit
|
||||
str = QString("");
|
||||
for (int i=0; i<fMsrFileNames.size()-1; i++) {
|
||||
str += fMsrFileNames[i] + " ";
|
||||
}
|
||||
str += fMsrFileNames[fMsrFileNames.size()-1];
|
||||
|
||||
fMsrFileSelector_lineEdit->setText(str);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when the fMsrFileNameClear_pushButton is clicked.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::clearMsrFileNames()
|
||||
{
|
||||
fMsrFileSelector_lineEdit->setText("");
|
||||
fMsrFilePaths.clear();
|
||||
fMsrFileNames.clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when fDataFileSelector_pushButton is clicked. Collects the data-file path-name list.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::selectDataFileNames()
|
||||
{
|
||||
QStringList flns = QFileDialog::getOpenFileNames( this, tr("Open msr-File(s)"), tr( "./" ),
|
||||
tr( "data-Files (*.root *.bin *.msr *.nxs *.mdu);;All Files (*)" ));
|
||||
|
||||
QString str(""), str1("");
|
||||
int idx;
|
||||
if (flns.size() > 0) {
|
||||
// delete already present elements
|
||||
fDataFilePaths.clear();
|
||||
fDataFileNames.clear();
|
||||
|
||||
// split path-name into path and name
|
||||
for (int i=0; i<flns.size(); i++) {
|
||||
str = flns[i];
|
||||
idx = str.lastIndexOf("/");
|
||||
str1 = str;
|
||||
str.remove(idx, str.length()-idx);
|
||||
fDataFilePaths << str;
|
||||
str1.remove(0, idx+1);
|
||||
fDataFileNames << str1;
|
||||
}
|
||||
|
||||
// populate fMsrFileSelector_lineEdit
|
||||
str = QString("");
|
||||
for (int i=0; i<fDataFileNames.size()-1; i++) {
|
||||
str += fDataFileNames[i] + " ";
|
||||
}
|
||||
str += fDataFileNames[fDataFileNames.size()-1];
|
||||
|
||||
fDataFileSelector_lineEdit->setText(str);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when the fDataFileNameClear_pushButton is clicked.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::clearDataFileNames()
|
||||
{
|
||||
fDataFileSelector_lineEdit->setText("");
|
||||
fDataFilePaths.clear();
|
||||
fDataFileNames.clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when the create-msr-file tag has changed
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::createMsrFileChanged(int state)
|
||||
{
|
||||
if (state == Qt::Checked) {
|
||||
fCreateMsrFileName = QFileDialog::getSaveFileName(this, tr("Create msr-file"), "./", tr("msr-Files (*.msr);;All Files (*)"));
|
||||
if (fCreateMsrFileName.length() == 0)
|
||||
fCreateMsrFile_checkBox->setCheckState(Qt::Unchecked);
|
||||
} else {
|
||||
fCreateMsrFileName = "";
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when the Reset All button is pressed. Will remove all settings.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::resetAll()
|
||||
{
|
||||
fCurrentMsrFile_checkBox->setCheckState(Qt::Unchecked);
|
||||
fAllMsrFiles_checkBox->setCheckState(Qt::Unchecked);
|
||||
fMsrFilePaths.clear();
|
||||
fMsrFileNames.clear();
|
||||
fMsrFileSelector_lineEdit->setText("");
|
||||
fDataFilePaths.clear();
|
||||
fDataFileNames.clear();
|
||||
fDataFileSelector_lineEdit->setText("");
|
||||
fBkgRangeStartBin_lineEdit->setText("");
|
||||
fBkgRangeEndBin_lineEdit->setText("");
|
||||
fBkgList_lineEdit->setText("");
|
||||
fApodization_comboBox->setCurrentIndex(MUSRFT_APOD_UNDEF);
|
||||
fPacking_lineEdit->setText("");
|
||||
fTimeRangeStart_lineEdit->setText("");
|
||||
fTimeRangeEnd_lineEdit->setText("");
|
||||
fHistoList_lineEdit->setText("");
|
||||
fT0_lineEdit->setText("");
|
||||
fFourierOption_comboBox->setCurrentIndex(MUSRFT_OPT_UNDEF);
|
||||
fFourierUnits_comboBox->setCurrentIndex(MUSRFT_UNIT_UNDEF);
|
||||
fFourierPower_lineEdit->setText("");
|
||||
fLifetimeCorrection_lineEdit->setText("");
|
||||
fFourierRangeStart_lineEdit->setText("");
|
||||
fFourierRangeEnd_lineEdit->setText("");
|
||||
fAveragedView_checkBox->setCheckState(Qt::Unchecked);
|
||||
fAveragePerDataSet_checkBox->setCheckState(Qt::Unchecked);
|
||||
fCreateMsrFile_checkBox->setCheckState(Qt::Unchecked);
|
||||
fFourierTitle_lineEdit->setText("");
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when averaged view for ALL data is checked.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::averagedAll(int state)
|
||||
{
|
||||
if ((state == Qt::Checked) && fAveragePerDataSet_checkBox->isChecked())
|
||||
fAveragePerDataSet_checkBox->setCheckState(Qt::Unchecked);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT called when averaged view per data set is checked.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::averagedPerDataSet(int state)
|
||||
{
|
||||
if ((state == Qt::Checked) && fAveragedView_checkBox->isChecked())
|
||||
fAveragedView_checkBox->setCheckState(Qt::Unchecked);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description for musrFT.
|
||||
*/
|
||||
void PGetMusrFTOptionsDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
71
src/musredit_qt5/PGetMusrFTOptionsDialog.h
Normal file
@ -0,0 +1,71 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetMusrFTOptionsDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2015 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETMUSRFTOPTIONSDIALOG_H_
|
||||
#define _PGETMUSRFTOPTIONSDIALOG_H_
|
||||
|
||||
#include <QDialog>
|
||||
#include <QStringList>
|
||||
|
||||
#include "ui_PGetMusrFTOptionsDialog.h"
|
||||
|
||||
class PGetMusrFTOptionsDialog : public QDialog, private Ui::PGetMusrFTOptionsDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetMusrFTOptionsDialog(QString currentMsrFile, QStringList &prevCmd, const QString helpUrl);
|
||||
QStringList getMusrFTOptions();
|
||||
|
||||
public slots:
|
||||
void helpContent();
|
||||
|
||||
private slots:
|
||||
void currentMsrFileTagChanged(int state);
|
||||
void allMsrFileTagChanged(int state);
|
||||
void selectMsrFileNames();
|
||||
void clearMsrFileNames();
|
||||
void selectDataFileNames();
|
||||
void clearDataFileNames();
|
||||
void createMsrFileChanged(int state);
|
||||
void resetAll();
|
||||
void averagedAll(int state);
|
||||
void averagedPerDataSet(int state);
|
||||
|
||||
private:
|
||||
QStringList fMsrFilePaths; ///< list keeping all the paths from the msr-file path-name list
|
||||
QStringList fMsrFileNames; ///< list keeping all the names from the msr-file path-name list
|
||||
QStringList fDataFilePaths; ///< list keeping all the paths from the data-file path-name list
|
||||
QStringList fDataFileNames; ///< list keeping all the names from the data-file path-name list
|
||||
QString fCreateMsrFileName; ///< keeps the msr-path-file name for msr-file creation
|
||||
QString fCurrentMsrFileName; ///< keeps the msr-path-file name of the currently active msr-file in musredit.
|
||||
QString fHelpUrl; ///< help url for the asymmetry run block
|
||||
};
|
||||
|
||||
#endif // _PGETMUSRFTOPTIONSDIALOG_H_
|
170
src/musredit_qt5/PGetNonMusrRunBlockDialog.cpp
Normal file
@ -0,0 +1,170 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetNonMusrRunBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QComboBox>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetNonMusrRunBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor
|
||||
*
|
||||
* \param helpUrl help url for the NonMusr run block.
|
||||
*/
|
||||
PGetNonMusrRunBlockDialog::PGetNonMusrRunBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fFitRangeStart_lineEdit->setValidator( new QDoubleValidator(fFitRangeStart_lineEdit) );
|
||||
fFitRangeEnd_lineEdit->setValidator( new QDoubleValidator(fFitRangeEnd_lineEdit) );
|
||||
|
||||
int idx = -1;
|
||||
for (int i=0; i<fFileFormat_comboBox->count(); i++) {
|
||||
if (fFileFormat_comboBox->itemText(i) == "DB") {
|
||||
idx = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (idx >= 0) {
|
||||
fFileFormat_comboBox->setCurrentIndex(idx);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts the run header information from the dialog, and returns it as a string.
|
||||
*/
|
||||
QString PGetNonMusrRunBlockDialog::getRunHeaderInfo()
|
||||
{
|
||||
QString str;
|
||||
|
||||
str = "RUN " + fRunFileName_lineEdit->text() + " ";
|
||||
str += fBeamline_lineEdit->text().toUpper() + " ";
|
||||
str += fInstitute_comboBox->currentText() + " ";
|
||||
str += fFileFormat_comboBox->currentText() + " (name beamline institute data-file-format)\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts the map from the dialog, and returns it as a string.
|
||||
*
|
||||
* \param valid flag indicating of the map is potentially being valid.
|
||||
*/
|
||||
QString PGetNonMusrRunBlockDialog::getMap(bool &valid)
|
||||
{
|
||||
QString str = fMap_lineEdit->text().trimmed().remove(" ");
|
||||
|
||||
// check if potentially proper map line
|
||||
for (int i=0; i<str.length(); i++) {
|
||||
if (!str[i].isDigit()) {
|
||||
valid = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
str = "map " + fMap_lineEdit->text() + "\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts xy-data from the dialog and returns it as a string.
|
||||
*
|
||||
* \param valid flag showing that x/y-data are present.
|
||||
*/
|
||||
QString PGetNonMusrRunBlockDialog::getXYData(bool &valid)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (fXData_lineEdit->text().isEmpty() || fYData_lineEdit->text().isEmpty()) {
|
||||
valid = false;
|
||||
} else {
|
||||
str = "xy-data ";
|
||||
str += fXData_lineEdit->text() + " ";
|
||||
str += fYData_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts the fit-range from the dialog and returns it as a string. If not fit-range was given,
|
||||
* a fit-range from 0 to 10 us will be returned and the valid flag will be set to false.
|
||||
*
|
||||
* \param valid flag showing if a fit-range is given.
|
||||
*/
|
||||
QString PGetNonMusrRunBlockDialog::getFitRange(bool &valid)
|
||||
{
|
||||
QString str = "";
|
||||
|
||||
if (fFitRangeStart_lineEdit->text().isEmpty() || fFitRangeEnd_lineEdit->text().isEmpty()) {
|
||||
str += "fit 0.0 10.0\n";
|
||||
valid = false;
|
||||
} else {
|
||||
str += "fit ";
|
||||
str += fFitRangeStart_lineEdit->text() + " ";
|
||||
str += fFitRangeEnd_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the NonMusr run block.
|
||||
*/
|
||||
void PGetNonMusrRunBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
58
src/musredit_qt5/PGetNonMusrRunBlockDialog.h
Normal file
@ -0,0 +1,58 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetNonMusrRunBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETNONMUSRRUNBLOCKDIALOG_H_
|
||||
#define _PGETNONMUSRRUNBLOCKDIALOG_H_
|
||||
|
||||
#include "ui_PGetNonMusrRunBlockDialog.h"
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handles the content of the NonMusr run block dialog.
|
||||
*/
|
||||
class PGetNonMusrRunBlockDialog : public QDialog, private Ui::PGetNonMusrRunBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetNonMusrRunBlockDialog(const QString helpUrl = "");
|
||||
|
||||
QString getRunHeaderInfo();
|
||||
QString getMap(bool &valid);
|
||||
QString getXYData(bool &valid);
|
||||
QString getFitRange(bool &valid);
|
||||
|
||||
private slots:
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url address for the NonMusr run block.
|
||||
};
|
||||
|
||||
#endif // _PGETNONMUSRRUNBLOCKDIALOG_H_
|
233
src/musredit_qt5/PGetParameterBlockDialog.cpp
Normal file
@ -0,0 +1,233 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetParameterBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QMessageBox>
|
||||
#include <QSpinBox>
|
||||
#include <QTextEdit>
|
||||
#include <QPushButton>
|
||||
#include <QEvent>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetParameterBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url of the PARAMETER block.
|
||||
*/
|
||||
PGetParameterBlockDialog::PGetParameterBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
// setup event filter
|
||||
installEventFilter(this);
|
||||
|
||||
fValue_lineEdit->setValidator( new QDoubleValidator(fValue_lineEdit) );
|
||||
fStep_lineEdit->setValidator( new QDoubleValidator(fStep_lineEdit) );
|
||||
|
||||
fParam_plainTextEdit->setFont(QFont("Courier", 10));
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This event filter is filtering out the return key, and if present adds the current parameters
|
||||
* to the parameter list.
|
||||
*
|
||||
* \param obj object which was generating the event.
|
||||
* \param ev event of the object.
|
||||
*/
|
||||
bool PGetParameterBlockDialog::eventFilter( QObject *obj, QEvent *ev )
|
||||
{
|
||||
if (obj == this) {
|
||||
if (ev->type() == QEvent::KeyPress) {
|
||||
QKeyEvent *k = (QKeyEvent*)ev;
|
||||
if (k->key() == Qt::Key_Return) {
|
||||
paramAdd();
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Adds a parameter to the text edit window.
|
||||
*/
|
||||
void PGetParameterBlockDialog::paramAdd()
|
||||
{
|
||||
QString param, str, spaces;
|
||||
|
||||
// get No
|
||||
str = fParamNo_spinBox->text();
|
||||
if (str.toInt() < 10)
|
||||
param = " " + str + " ";
|
||||
else
|
||||
param = " " + str + " ";
|
||||
|
||||
// get name
|
||||
str = fName_lineEdit->text();
|
||||
if (str.isEmpty()) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"empty parameter name not allowed!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
} else {
|
||||
param += str;
|
||||
if (str.length() < 13)
|
||||
param += spaces.fill(' ', 13-str.length());
|
||||
else
|
||||
param += " ";
|
||||
}
|
||||
|
||||
// get value
|
||||
str = fValue_lineEdit->text();
|
||||
if (str.isEmpty()) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"empty parameter value not allowed!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
} else {
|
||||
param += str;
|
||||
if (str.length() < 10)
|
||||
param += spaces.fill(' ', 10-str.length());
|
||||
else
|
||||
param += " ";
|
||||
}
|
||||
|
||||
// get step
|
||||
str = fStep_lineEdit->text();
|
||||
if (str.isEmpty()) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"empty parameter step not allowed!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
} else {
|
||||
param += str;
|
||||
if (str.length() < 10)
|
||||
param += spaces.fill(' ', 10-str.length());
|
||||
else
|
||||
param += " ";
|
||||
}
|
||||
|
||||
// add positive error none
|
||||
param += "none ";
|
||||
|
||||
if ((fLower_lineEdit->text() != "none") || (fUpper_lineEdit->text() != "none")) {
|
||||
// get lower boundary
|
||||
str = fLower_lineEdit->text();
|
||||
bool ok;
|
||||
double val = str.toDouble(&ok);
|
||||
if (!ok && (str != "none")) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"invalid lower boundary! Must be a double are the key word 'none'",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
} else {
|
||||
param += str;
|
||||
if (str.length() < 10)
|
||||
param += spaces.fill(' ', 10-str.length());
|
||||
else
|
||||
param += " ";
|
||||
}
|
||||
|
||||
// get upper boundary
|
||||
str = fUpper_lineEdit->text();
|
||||
val = str.toDouble(&ok);
|
||||
if (!ok && (str != "none")) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"invalid upper boundary! Must be a double are the key word 'none'",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
} else {
|
||||
param += str;
|
||||
if (str.length() < 10)
|
||||
param += spaces.fill(' ', 10-str.length());
|
||||
else
|
||||
param += " ";
|
||||
}
|
||||
}
|
||||
|
||||
// param += "\n";
|
||||
|
||||
// write parameter string into fParam_textEdit
|
||||
fParam_plainTextEdit->appendPlainText(param);
|
||||
|
||||
// increment No counter in spinBox
|
||||
fParamNo_spinBox->stepUp();
|
||||
|
||||
// reset name lineEdit
|
||||
fName_lineEdit->setText("");
|
||||
|
||||
// reset value lineEdit
|
||||
fValue_lineEdit->setText("");
|
||||
|
||||
// reset step lineEdit
|
||||
fStep_lineEdit->setText("");
|
||||
|
||||
// reset lower boundary lineEdit
|
||||
fLower_lineEdit->setText("none");
|
||||
|
||||
// reset upper boundary lineEdit
|
||||
fUpper_lineEdit->setText("none");
|
||||
|
||||
fName_lineEdit->setFocus();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the FITPARAMETER block.
|
||||
*/
|
||||
void PGetParameterBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
59
src/musredit_qt5/PGetParameterBlockDialog.h
Normal file
@ -0,0 +1,59 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetParameterBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETPARAMETERBLOCKDIALOG_H_
|
||||
#define _PGETPARAMETERBLOCKDIALOG_H_
|
||||
|
||||
#include "ui_PGetParameterBlockDialog.h"
|
||||
|
||||
//-----------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handles the content of the PARAMETER block dialog.
|
||||
*/
|
||||
class PGetParameterBlockDialog : public QDialog, private Ui::PGetParameterBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetParameterBlockDialog(const QString helpUrl);
|
||||
|
||||
QString getParams() { return fParam_plainTextEdit->toPlainText(); }
|
||||
|
||||
protected:
|
||||
bool eventFilter( QObject *obj, QEvent *ev );
|
||||
|
||||
private slots:
|
||||
void paramAdd();
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url of the PARAMETER block description.
|
||||
};
|
||||
|
||||
#endif // _PGETPARAMETERBLOCKDIALOG_H_
|
200
src/musredit_qt5/PGetPlotBlockDialog.cpp
Normal file
@ -0,0 +1,200 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetPlotBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QMessageBox>
|
||||
#include <QSpinBox>
|
||||
#include <QTextEdit>
|
||||
#include <QComboBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetPlotBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url for the PLOT block.
|
||||
*/
|
||||
PGetPlotBlockDialog::PGetPlotBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
// setup event filter
|
||||
installEventFilter(this);
|
||||
|
||||
fXRangeLow_lineEdit->setValidator( new QDoubleValidator(fXRangeLow_lineEdit) );
|
||||
fXRangeUp_lineEdit->setValidator( new QDoubleValidator(fXRangeUp_lineEdit) );
|
||||
fYRangeLow_lineEdit->setValidator( new QDoubleValidator(fYRangeLow_lineEdit) );
|
||||
fYRangeUp_lineEdit->setValidator( new QDoubleValidator(fYRangeUp_lineEdit) );
|
||||
|
||||
fPlot_plainTextEdit->setFont(QFont("Courier", 10));
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Extracts the information of the top part of the dialog, constructs a msr-file PLOT block and
|
||||
* writes it into the text edit window.
|
||||
*/
|
||||
void PGetPlotBlockDialog::addPlot()
|
||||
{
|
||||
QString param = "";
|
||||
QString str = "";
|
||||
QString spaces;
|
||||
|
||||
// add begining of plot block if fPlot_plainTextEdit is still empty
|
||||
if (fPlot_plainTextEdit->toPlainText().isEmpty()) {
|
||||
param = "###############################################################\n";
|
||||
}
|
||||
|
||||
// write type
|
||||
param += "PLOT ";
|
||||
if (fType_comboBox->currentText() == "Single Histo") {
|
||||
param += "0 (single histo plot)\n";
|
||||
} else if (fType_comboBox->currentText() == "Asymmetry") {
|
||||
param += "2 (asymmetry plot)\n";
|
||||
} else if (fType_comboBox->currentText() == "MuMinus") {
|
||||
param += "4 (mu minus plot)\n";
|
||||
} else if (fType_comboBox->currentText() == "NonMusr") {
|
||||
param += "8 (non muSR plot)\n";
|
||||
}
|
||||
|
||||
// write runs
|
||||
param += "runs " + fRunList_lineEdit->text() + "\n";
|
||||
|
||||
// write range
|
||||
param += "range ";
|
||||
// lower x-/time range
|
||||
str = fXRangeLow_lineEdit->text();
|
||||
if (str.isEmpty()) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"empty lower time-/x-range name not allowed!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
}
|
||||
param += str;
|
||||
if (str.length() < 8)
|
||||
param += spaces.fill(' ', 8 - str.length());
|
||||
else
|
||||
param += " ";
|
||||
|
||||
// upper x-/time range
|
||||
str = fXRangeUp_lineEdit->text();
|
||||
if (str.isEmpty()) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"empty upper time-/x-range name not allowed!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
return;
|
||||
}
|
||||
param += str;
|
||||
if (str.length() < 8)
|
||||
param += spaces.fill(' ', 8 - str.length());
|
||||
else
|
||||
param += " ";
|
||||
|
||||
// check y-range: either none given or both
|
||||
if ((fYRangeLow_lineEdit->text().isEmpty() && !fYRangeUp_lineEdit->text().isEmpty()) ||
|
||||
(!fYRangeLow_lineEdit->text().isEmpty() && fYRangeUp_lineEdit->text().isEmpty())) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Only fully empty y-range, or give lower AND upper y-range is acceptable!\n Will ignore the y-range",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
} else if (!fYRangeLow_lineEdit->text().isEmpty() && !fYRangeUp_lineEdit->text().isEmpty()) {
|
||||
str = fYRangeLow_lineEdit->text();
|
||||
param += str;
|
||||
if (str.length() < 8)
|
||||
param += spaces.fill(' ', 8 - str.length());
|
||||
else
|
||||
param += " ";
|
||||
param += fYRangeUp_lineEdit->text() + "\n";
|
||||
} else {
|
||||
param += "\n";
|
||||
}
|
||||
param += "\n";
|
||||
|
||||
fPlot_plainTextEdit->appendPlainText(param);
|
||||
|
||||
// clean input
|
||||
fRunList_lineEdit->clear();
|
||||
fXRangeLow_lineEdit->clear();
|
||||
fXRangeUp_lineEdit->clear();
|
||||
fYRangeLow_lineEdit->clear();
|
||||
fYRangeUp_lineEdit->clear();
|
||||
fRunList_lineEdit->setFocus();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the PLOT block.
|
||||
*/
|
||||
void PGetPlotBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>This event filter is filtering out the return key, and if present adds the current plot.
|
||||
*
|
||||
* \param obj object which is triggering the event
|
||||
* \param ev the triggered event
|
||||
*/
|
||||
bool PGetPlotBlockDialog::eventFilter( QObject *obj, QEvent *ev )
|
||||
{
|
||||
if (obj == this) {
|
||||
if (ev->type() == QEvent::KeyPress) {
|
||||
QKeyEvent *k = (QKeyEvent*)ev;
|
||||
if (k->key() == Qt::Key_Return) {
|
||||
addPlot();
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
59
src/musredit_qt5/PGetPlotBlockDialog.h
Normal file
@ -0,0 +1,59 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetPlotBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETPLOTBLOCKDIALOG_H_
|
||||
#define _PGETPLOTBLOCKDIALOG_H_
|
||||
|
||||
#include "ui_PGetPlotBlockDialog.h"
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handels content of the PLOT block dialog.
|
||||
*/
|
||||
class PGetPlotBlockDialog : public QDialog, private Ui::PGetPlotBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetPlotBlockDialog(const QString helpUrl);
|
||||
|
||||
QString getPlotBlock() { return fPlot_plainTextEdit->toPlainText(); }
|
||||
|
||||
public slots:
|
||||
void addPlot();
|
||||
void helpContent();
|
||||
|
||||
protected:
|
||||
bool eventFilter( QObject *obj, QEvent *ev );
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url for the PLOT block
|
||||
};
|
||||
|
||||
#endif // _PGETPLOTBLOCKDIALOG_H_
|
296
src/musredit_qt5/PGetSingleHistoRunBlockDialog.cpp
Normal file
@ -0,0 +1,296 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetSingleHistoRunBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QComboBox>
|
||||
#include <QCheckBox>
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetSingleHistoRunBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url for the asymmetry run block
|
||||
* \param lifetimeCorrection flag indicating if lifetime correction shall be enabled.
|
||||
*/
|
||||
PGetSingleHistoRunBlockDialog::PGetSingleHistoRunBlockDialog(const QString helpUrl,
|
||||
const bool lifetimeCorrection) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fForwardHistoNo_lineEdit->setValidator( new QIntValidator(fForwardHistoNo_lineEdit) );
|
||||
fNorm_lineEdit->setValidator( new QIntValidator(fNorm_lineEdit) );
|
||||
fDataStart_lineEdit->setValidator( new QIntValidator(fDataStart_lineEdit) );
|
||||
fDataEnd_lineEdit->setValidator( new QIntValidator(fDataEnd_lineEdit) );
|
||||
fBackgroundFix_lineEdit->setValidator( new QDoubleValidator(fBackgroundFix_lineEdit) );
|
||||
fBackgroundFit_lineEdit->setValidator( new QIntValidator(fBackgroundFit_lineEdit) );
|
||||
fBackgroundStart_lineEdit->setValidator( new QIntValidator(fBackgroundStart_lineEdit) );
|
||||
fBackgroundEnd_lineEdit->setValidator( new QIntValidator(fBackgroundEnd_lineEdit) );
|
||||
fFitRangeStart_lineEdit->setValidator( new QDoubleValidator(fFitRangeStart_lineEdit) );
|
||||
fFitRangeEnd_lineEdit->setValidator( new QDoubleValidator(fFitRangeEnd_lineEdit) );
|
||||
fPacking_lineEdit->setValidator( new QIntValidator(fPacking_lineEdit) );
|
||||
fT0_lineEdit->setValidator( new QIntValidator(fT0_lineEdit) );
|
||||
fLifetime_lineEdit->setValidator( new QIntValidator(fLifetime_lineEdit) );
|
||||
fLifetimeCorrection_checkBox->setChecked(lifetimeCorrection);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the run information line of the single histogram run block.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getRunHeaderInfo()
|
||||
{
|
||||
QString str="";
|
||||
|
||||
str = "RUN " + fRunFileName_lineEdit->text() + " ";
|
||||
str += fBeamline_lineEdit->text().toUpper() + " ";
|
||||
str += fInstitute_comboBox->currentText() + " ";
|
||||
str += fFileFormat_comboBox->currentText() + " (name beamline institute data-file-format)\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the map for the single histogram run block.
|
||||
*
|
||||
* \param valid flag indicating if the map is potentially valid.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getMap(bool &valid)
|
||||
{
|
||||
QString str = fMap_lineEdit->text().trimmed().remove(" ");
|
||||
|
||||
// check if potentially proper map line
|
||||
for (int i=0; i<str.length(); i++) {
|
||||
if (!str[i].isDigit()) {
|
||||
valid = false;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
str = "map " + fMap_lineEdit->text() + "\n";
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a data range (in bins) entry for the single histogram run block.
|
||||
*
|
||||
* \param valid flag indicating if the data entries are valid.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getData(bool &valid)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (fDataStart_lineEdit->text().isEmpty() || fDataEnd_lineEdit->text().isEmpty()) {
|
||||
valid = false;
|
||||
} else {
|
||||
str = "data ";
|
||||
str += fDataStart_lineEdit->text() + " ";
|
||||
str += fDataEnd_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the background information for the single histogram run block.
|
||||
*
|
||||
* \param valid flag indicating if a valid background (either backgr.fix, background, or backgr.fit is given, but only one)
|
||||
* is present.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getBackground(bool &valid)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
valid = true;
|
||||
|
||||
// check that either backgr.fix or background is given, but not both
|
||||
if (fBackgroundStart_lineEdit->text().isEmpty() && fBackgroundEnd_lineEdit->text().isEmpty() &&
|
||||
fBackgroundFix_lineEdit->text().isEmpty() &&
|
||||
fBackgroundFit_lineEdit->text().isEmpty()) {
|
||||
valid = false;
|
||||
str = "background 0 10\n";
|
||||
} else {
|
||||
if (!fBackgroundStart_lineEdit->text().isEmpty()) { // assume the rest is given, not fool prove but ...
|
||||
str = "background ";
|
||||
str += fBackgroundStart_lineEdit->text() + " ";
|
||||
str += fBackgroundEnd_lineEdit->text() + "\n";
|
||||
}
|
||||
if (!fBackgroundFix_lineEdit->text().isEmpty()) {
|
||||
str = "backgr.fix ";
|
||||
str += fBackgroundFix_lineEdit->text() + "\n";
|
||||
}
|
||||
if (!fBackgroundFit_lineEdit->text().isEmpty()) {
|
||||
str = "backgr.fit ";
|
||||
str += fBackgroundFit_lineEdit->text() + "\n";
|
||||
}
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a fit range entry for the single histogram run block. If no fit range has been provided,
|
||||
* a fit range [0,10] will be set and the valid flag will be set to false.
|
||||
*
|
||||
* \param valid flag indicating if a fit range was provided.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getFitRange(bool &valid)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (fFitRangeStart_lineEdit->text().isEmpty() || fFitRangeEnd_lineEdit->text().isEmpty()) {
|
||||
str += "fit 0.0 10.0\n";
|
||||
valid = false;
|
||||
} else {
|
||||
str += "fit ";
|
||||
str += fFitRangeStart_lineEdit->text() + " ";
|
||||
str += fFitRangeEnd_lineEdit->text() + "\n";
|
||||
valid = true;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the packing/binning of the single histogram run block. If no packing has been provided,
|
||||
* a packing of '1' will be set and the present flag will be set to false.
|
||||
*
|
||||
* \param present flag indicating if a packing parameter was provided.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getPacking(bool &present)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (fPacking_lineEdit->text().isEmpty()) {
|
||||
present = false;
|
||||
str += "packing 1\n";
|
||||
} else {
|
||||
present = true;
|
||||
str += "packing " + fPacking_lineEdit->text() + "\n\n";
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns a t0 parameter for the single histogram run block.
|
||||
*
|
||||
* \param present flag indicating if a t0 parameter is set.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getT0(bool &present)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (!fT0_lineEdit->text().isEmpty()) {
|
||||
str = "t0 ";
|
||||
str += fT0_lineEdit->text() + "\n";
|
||||
present = true;
|
||||
} else {
|
||||
present = false;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the muon lifetime parameter if present.
|
||||
*
|
||||
* \param present flag indicating if a muon life time parameter has been present.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getMuonLifetimeParam(bool &present)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (!fLifetime_lineEdit->text().isEmpty()) {
|
||||
str = "lifetime ";
|
||||
str += fLifetime_lineEdit->text() + "\n";
|
||||
present = true;
|
||||
} else {
|
||||
present = false;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the lifetime correction flag.
|
||||
*
|
||||
* \param present flag showing if the lifetime correction flag should be set.
|
||||
*/
|
||||
QString PGetSingleHistoRunBlockDialog::getLifetimeCorrection(bool &present)
|
||||
{
|
||||
QString str="";
|
||||
|
||||
if (fLifetimeCorrection_checkBox->isChecked()) {
|
||||
str = "lifetimecorrection\n";
|
||||
present = true;
|
||||
} else {
|
||||
present = false;
|
||||
}
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the single histogram run block.
|
||||
*/
|
||||
void PGetSingleHistoRunBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
68
src/musredit_qt5/PGetSingleHistoRunBlockDialog.h
Normal file
@ -0,0 +1,68 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetSingleHistoRunBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETSINGLEHISTORUNBLOCKDIALOG_H_
|
||||
#define _PGETSINGLEHISTORUNBLOCKDIALOG_H_
|
||||
|
||||
#include <QString>
|
||||
#include <QLineEdit>
|
||||
|
||||
#include "ui_PGetSingleHistoRunBlockDialog.h"
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class handling the content of the menu: Edit/Add Block/Single Histo Run Block.
|
||||
*/
|
||||
class PGetSingleHistoRunBlockDialog : public QDialog, private Ui::PGetSingleHistoRunBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetSingleHistoRunBlockDialog(const QString helpUrl = "", const bool lifetimeCorrection = true);
|
||||
|
||||
QString getRunHeaderInfo();
|
||||
QString getMap(bool &valid);
|
||||
QString getForward() { return QString("forward " + fForwardHistoNo_lineEdit->text() + "\n"); }
|
||||
QString getNorm() { return QString("norm " + fNorm_lineEdit->text() + "\n"); }
|
||||
QString getData(bool &valid);
|
||||
QString getBackground(bool &valid);
|
||||
QString getFitRange(bool &valid);
|
||||
QString getPacking(bool &present);
|
||||
QString getT0(bool &present);
|
||||
QString getMuonLifetimeParam(bool &present);
|
||||
QString getLifetimeCorrection(bool &present);
|
||||
|
||||
private slots:
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url for the asymmetry run block
|
||||
};
|
||||
|
||||
#endif // _PGETSINGLEHISTORUNBLOCKDIALOG_H_
|
140
src/musredit_qt5/PGetTheoryBlockDialog.cpp
Normal file
@ -0,0 +1,140 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetTheoryBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QMessageBox>
|
||||
#include <QTextEdit>
|
||||
#include <QComboBox>
|
||||
#include <QPixmap>
|
||||
#include <QImage>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetTheoryBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param admin pointer to the administration class object needed to extract the default theory set informations.
|
||||
* \param helpUrl help url for the asymmetry run block
|
||||
*/
|
||||
PGetTheoryBlockDialog::PGetTheoryBlockDialog(PAdmin *admin, const QString helpUrl) :
|
||||
fAdmin(admin),
|
||||
fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
// feed theory function combo box
|
||||
fTheoryFunction_comboBox->setIconSize(QSize(250, 20));
|
||||
PTheory *theoItem;
|
||||
QIcon *icon;
|
||||
QString iconName;
|
||||
for (unsigned int i=0; i<fAdmin->getTheoryCounts(); i++) {
|
||||
theoItem = fAdmin->getTheoryItem(i);
|
||||
if (theoItem->pixmapName.length() > 0) {
|
||||
iconName = QString(":/latex_images/") + theoItem->pixmapName;
|
||||
icon = new QIcon(QPixmap(iconName));
|
||||
fTheoryFunction_comboBox->insertItem(i, *icon, theoItem->label);
|
||||
} else {
|
||||
fTheoryFunction_comboBox->insertItem(i, theoItem->label);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the theory function string of the currently selected theory function.
|
||||
*/
|
||||
QString PGetTheoryBlockDialog::getTheoFuncString()
|
||||
{
|
||||
QString str = "????";
|
||||
int idx = fTheoryFunction_comboBox->currentIndex();
|
||||
PTheory *theoItem = fAdmin->getTheoryItem(idx);
|
||||
if (theoItem == 0)
|
||||
return str;
|
||||
|
||||
// add theory function name
|
||||
str = theoItem->name + " ";
|
||||
if (theoItem->name == "userFcn") {
|
||||
str += "libMyLibrary.so TMyFunction ";
|
||||
}
|
||||
// add pseudo parameters
|
||||
for (int i=0; i<theoItem->params; i++) {
|
||||
str += QString("%1").arg(i+1) + " ";
|
||||
}
|
||||
// add comment
|
||||
str += theoItem->comment;
|
||||
|
||||
return str;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>adds the current theory function to the text field and additionally adds a '+'.
|
||||
*/
|
||||
void PGetTheoryBlockDialog::addPlus()
|
||||
{
|
||||
QString str = getTheoFuncString() + "\n+";
|
||||
fTheoryBlock_plainTextEdit->appendPlainText(str);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>adds the current theory function to the text field (newline == '*').
|
||||
*/
|
||||
void PGetTheoryBlockDialog::addMultiply()
|
||||
{
|
||||
QString str = getTheoFuncString();
|
||||
fTheoryBlock_plainTextEdit->appendPlainText(str);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of the theory block.
|
||||
*/
|
||||
void PGetTheoryBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
60
src/musredit_qt5/PGetTheoryBlockDialog.h
Normal file
@ -0,0 +1,60 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetTheoryBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETTHEORYBLOCKDIALOG_H_
|
||||
#define _PGETTHEORYBLOCKDIALOG_H_
|
||||
|
||||
#include "PAdmin.h"
|
||||
#include "ui_PGetTheoryBlockDialog.h"
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class handling the content of the menu: Edit/Add Block/Theory Block.
|
||||
*/
|
||||
class PGetTheoryBlockDialog : public QDialog, private Ui::PGetTheoryBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetTheoryBlockDialog(PAdmin *admin = 0, const QString helpUrl = "");
|
||||
|
||||
QString getTheoryBlock() { return fTheoryBlock_plainTextEdit->toPlainText(); }
|
||||
|
||||
private slots:
|
||||
QString getTheoFuncString();
|
||||
void addPlus();
|
||||
void addMultiply();
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
PAdmin *fAdmin; ///< pointer to the administration class object needed to extract the default theory set informations.
|
||||
QString fHelpUrl; ///< help url for the asymmetry run block
|
||||
};
|
||||
|
||||
#endif // _PGETTHEORYBLOCKDIALOG_H_
|
68
src/musredit_qt5/PGetTitleBlockDialog.cpp
Normal file
@ -0,0 +1,68 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetTitleBlockDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QMessageBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
#include "PGetTitleBlockDialog.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param helpUrl help url for the title.
|
||||
*/
|
||||
PGetTitleBlockDialog::PGetTitleBlockDialog(const QString helpUrl) : fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description of title block.
|
||||
*/
|
||||
void PGetTitleBlockDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
// END
|
||||
//---------------------------------------------------------------------------
|
57
src/musredit_qt5/PGetTitleBlockDialog.h
Normal file
@ -0,0 +1,57 @@
|
||||
/****************************************************************************
|
||||
|
||||
PGetTitleBlockDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PGETTITLEBLOCKDIALOG_H_
|
||||
#define _PGETTITLEBLOCKDIALOG_H_
|
||||
|
||||
#include "musredit.h"
|
||||
#include "ui_PGetTitleBlockDialog.h"
|
||||
|
||||
//--------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class handling the content of the menu: Edit/Add Block/Title Block.
|
||||
*/
|
||||
class PGetTitleBlockDialog : public QDialog, private Ui::PGetTitleBlockDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PGetTitleBlockDialog(const QString helpUrl);
|
||||
virtual ~PGetTitleBlockDialog() {}
|
||||
|
||||
QString getTitle() { return fTitle_lineEdit->text(); }
|
||||
|
||||
private slots:
|
||||
void helpContent();
|
||||
|
||||
private:
|
||||
QString fHelpUrl; ///< help url for the asymmetry run block
|
||||
};
|
||||
|
||||
#endif // _PGETTITLEBLOCKDIALOG_H_
|
157
src/musredit_qt5/PHelp.cpp
Normal file
@ -0,0 +1,157 @@
|
||||
/****************************************************************************
|
||||
|
||||
PHelp.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QtWidgets>
|
||||
#include <QtWebKitWidgets>
|
||||
#include <QNetworkProxyFactory>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param url help url
|
||||
*/
|
||||
PHelp::PHelp(const QString &url)
|
||||
{
|
||||
fProgress = 0;
|
||||
|
||||
QNetworkProxyFactory::setUseSystemConfiguration(true);
|
||||
|
||||
fView = new QWebView(this);
|
||||
fView->load(QUrl(url));
|
||||
connect(fView, SIGNAL(loadFinished(bool)), SLOT(adjustLocation()));
|
||||
connect(fView, SIGNAL(titleChanged(QString)), SLOT(adjustTitle()));
|
||||
connect(fView, SIGNAL(loadProgress(int)), SLOT(setProgress(int)));
|
||||
connect(fView, SIGNAL(loadFinished(bool)), SLOT(finishLoading(bool)));
|
||||
|
||||
fLocationEdit = new QLineEdit(this);
|
||||
fLocationEdit->setSizePolicy(QSizePolicy::Expanding, fLocationEdit->sizePolicy().verticalPolicy());
|
||||
connect(fLocationEdit, SIGNAL(returnPressed()), SLOT(changeLocation()));
|
||||
|
||||
QToolBar *toolBar = addToolBar(tr("Navigation"));
|
||||
toolBar->addAction(fView->pageAction(QWebPage::Back));
|
||||
toolBar->addAction(fView->pageAction(QWebPage::Forward));
|
||||
toolBar->addAction(fView->pageAction(QWebPage::Reload));
|
||||
toolBar->addAction(fView->pageAction(QWebPage::Stop));
|
||||
toolBar->addWidget(fLocationEdit);
|
||||
|
||||
QMenu *exitMenu = menuBar()->addMenu(tr("&File"));
|
||||
exitMenu->addAction("&Exit", this, SLOT(done()), QKeySequence(tr("Ctrl+Q")));
|
||||
|
||||
setCentralWidget(fView);
|
||||
setUnifiedTitleAndToolBarOnMac(true);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Destructor
|
||||
*/
|
||||
PHelp::~PHelp()
|
||||
{
|
||||
if (fView) {
|
||||
delete fView;
|
||||
fView = 0;
|
||||
}
|
||||
|
||||
if (fLocationEdit) {
|
||||
delete fLocationEdit;
|
||||
fLocationEdit = 0;
|
||||
}
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Called on exit (SLOT). Closes the web-browser help GUI.
|
||||
*/
|
||||
void PHelp::done()
|
||||
{
|
||||
close();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Called after an url is loaded (SLOT). Adjusts the url address.
|
||||
*/
|
||||
void PHelp::adjustLocation()
|
||||
{
|
||||
fLocationEdit->setText(fView->url().toString());
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Called when the url address in the line edit changed (SLOT). Will execute
|
||||
* the load of the new url.
|
||||
*/
|
||||
void PHelp::changeLocation()
|
||||
{
|
||||
QUrl url = QUrl(fLocationEdit->text());
|
||||
fView->load(url);
|
||||
fView->setFocus();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Called when the title changed (SLOT). Will change the window title according
|
||||
* to the state of the web-browser.
|
||||
*/
|
||||
void PHelp::adjustTitle()
|
||||
{
|
||||
if (fProgress <= 0 || fProgress >= 100)
|
||||
setWindowTitle(fView->title());
|
||||
else
|
||||
setWindowTitle(QString("%1 (%2%)").arg(fView->title()).arg(fProgress));
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Adjusts the progess value while loading an url. Also calls adjustTitle().
|
||||
*/
|
||||
void PHelp::setProgress(int p)
|
||||
{
|
||||
fProgress = p;
|
||||
adjustTitle();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Ajusts the title when an url has been loaded.
|
||||
*/
|
||||
void PHelp::finishLoading(bool)
|
||||
{
|
||||
fProgress = 100;
|
||||
adjustTitle();
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
// end
|
||||
//---------------------------------------------------------------------------
|
67
src/musredit_qt5/PHelp.h
Normal file
@ -0,0 +1,67 @@
|
||||
/****************************************************************************
|
||||
|
||||
PHelp.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2015 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PHELP_H_
|
||||
#define _PHELP_H_
|
||||
|
||||
#include <QtWidgets>
|
||||
|
||||
class QWebView;
|
||||
QT_BEGIN_NAMESPACE
|
||||
class QLineEdit;
|
||||
QT_END_NAMESPACE
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class providing the help interface for the user. It opens the wiki docu
|
||||
* pages such that a user has the chance to read.
|
||||
*/
|
||||
class PHelp : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PHelp(const QString &url);
|
||||
virtual ~PHelp();
|
||||
|
||||
protected slots:
|
||||
void done();
|
||||
void adjustLocation();
|
||||
void changeLocation();
|
||||
void adjustTitle();
|
||||
void setProgress(int p);
|
||||
void finishLoading(bool);
|
||||
|
||||
private:
|
||||
QWebView *fView; ///< web viewer
|
||||
QLineEdit *fLocationEdit; ///< url address line edit
|
||||
int fProgress; ///< progress value (0-100) while loading an url
|
||||
};
|
||||
|
||||
#endif // _PHELP_H_
|
329
src/musredit_qt5/PMsr2DataDialog.cpp
Normal file
@ -0,0 +1,329 @@
|
||||
/****************************************************************************
|
||||
|
||||
PMsr2DataDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QLineEdit>
|
||||
#include <QValidator>
|
||||
#include <QMessageBox>
|
||||
#include <QTextEdit>
|
||||
#include <QCheckBox>
|
||||
|
||||
#include "PHelp.h"
|
||||
|
||||
#include "PMsr2DataDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param msr2DataParam data structure keeping the necessary information to feed msr2data
|
||||
* \param helpUrl help url for msr2data
|
||||
*/
|
||||
PMsr2DataDialog::PMsr2DataDialog(PMsr2DataParam *msr2DataParam, const QString helpUrl) : fMsr2DataParam(msr2DataParam), fHelpUrl(helpUrl)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
QString str;
|
||||
|
||||
fRunTag = -1;
|
||||
|
||||
fFirst_lineEdit->setValidator( new QIntValidator(fFirst_lineEdit) );
|
||||
if (fMsr2DataParam->firstRun != -1) {
|
||||
str = QString("%1").arg(fMsr2DataParam->firstRun);
|
||||
fFirst_lineEdit->setText(str);
|
||||
}
|
||||
|
||||
fLast_lineEdit->setValidator( new QIntValidator(fLast_lineEdit) );
|
||||
if (fMsr2DataParam->lastRun != -1) {
|
||||
str = QString("%1").arg(fMsr2DataParam->lastRun);
|
||||
fLast_lineEdit->setText(str);
|
||||
}
|
||||
|
||||
if (!fMsr2DataParam->runListFileName.isEmpty()) {
|
||||
fRunListFileName_lineEdit->setText(fMsr2DataParam->runListFileName);
|
||||
}
|
||||
|
||||
if (!fMsr2DataParam->runList.isEmpty()) {
|
||||
fRunList_lineEdit->setText(fMsr2DataParam->runList);
|
||||
}
|
||||
|
||||
if (!fMsr2DataParam->msrFileExtension.isEmpty()) {
|
||||
fMsrFileExtension_lineEdit->setText(fMsr2DataParam->msrFileExtension);
|
||||
}
|
||||
|
||||
fTemplateRunNumber_lineEdit->setValidator( new QIntValidator(fTemplateRunNumber_lineEdit) );
|
||||
if (fMsr2DataParam->templateRunNo != -1) {
|
||||
str = QString("%1").arg(fMsr2DataParam->templateRunNo);
|
||||
fTemplateRunNumber_lineEdit->setText(str);
|
||||
}
|
||||
|
||||
if (!fMsr2DataParam->dbOutputFileName.isEmpty()) {
|
||||
fDataOutputFileName_lineEdit->setText(fMsr2DataParam->dbOutputFileName);
|
||||
}
|
||||
|
||||
fWriteDataHeader_checkBox->setChecked(fMsr2DataParam->writeDbHeader);
|
||||
fIgnoreDataHeaderInfo_checkBox->setChecked(fMsr2DataParam->ignoreDataHeaderInfo);
|
||||
fKeepMinuit2Output_checkBox->setChecked(fMsr2DataParam->keepMinuit2Output);
|
||||
fWriteColumnData_checkBox->setChecked(fMsr2DataParam->writeColumnData);
|
||||
fRecreateDataFile_checkBox->setChecked(fMsr2DataParam->recreateDbFile);
|
||||
fChainFit_checkBox->setChecked(fMsr2DataParam->chainFit);
|
||||
fOpenFilesAfterFitting_checkBox->setChecked(fMsr2DataParam->openFilesAfterFitting);
|
||||
fTitleFromData_checkBox->setChecked(fMsr2DataParam->titleFromDataFile);
|
||||
fCreateMsrFileOnly_checkBox->setChecked(fMsr2DataParam->createMsrFileOnly);
|
||||
fFitOnly_checkBox->setChecked(fMsr2DataParam->fitOnly);
|
||||
fGlobal_checkBox->setChecked(fMsr2DataParam->global);
|
||||
fGlobalPlus_checkBox->setChecked(fMsr2DataParam->globalPlus);
|
||||
|
||||
connect(fGlobal_checkBox, SIGNAL(clicked(bool)), this, SLOT(globalOptionSet(bool)));
|
||||
connect(fGlobalPlus_checkBox, SIGNAL(clicked(bool)), this, SLOT(globalPlusOptionSet(bool)));
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the msr2data relavant parameters from the GUI.
|
||||
*/
|
||||
PMsr2DataParam* PMsr2DataDialog::getMsr2DataParam()
|
||||
{
|
||||
if (fFirst_lineEdit->text().isEmpty()) {
|
||||
fMsr2DataParam->firstRun = -1;
|
||||
} else {
|
||||
fMsr2DataParam->firstRun = fFirst_lineEdit->text().toInt();
|
||||
}
|
||||
if (fLast_lineEdit->text().isEmpty()) {
|
||||
fMsr2DataParam->lastRun = -1;
|
||||
} else {
|
||||
fMsr2DataParam->lastRun = fLast_lineEdit->text().toInt();
|
||||
}
|
||||
fMsr2DataParam->runList = fRunList_lineEdit->text();
|
||||
fMsr2DataParam->runListFileName = fRunListFileName_lineEdit->text();
|
||||
fMsr2DataParam->msrFileExtension = fMsrFileExtension_lineEdit->text();
|
||||
if (fTemplateRunNumber_lineEdit->text().isEmpty()) {
|
||||
fMsr2DataParam->templateRunNo = -1;
|
||||
} else {
|
||||
fMsr2DataParam->templateRunNo = fTemplateRunNumber_lineEdit->text().toInt();
|
||||
}
|
||||
fMsr2DataParam->dbOutputFileName = fDataOutputFileName_lineEdit->text();
|
||||
fMsr2DataParam->writeDbHeader = fWriteDataHeader_checkBox->isChecked();
|
||||
fMsr2DataParam->ignoreDataHeaderInfo = fIgnoreDataHeaderInfo_checkBox->isChecked();
|
||||
fMsr2DataParam->keepMinuit2Output = fKeepMinuit2Output_checkBox->isChecked();
|
||||
fMsr2DataParam->writeColumnData = fWriteColumnData_checkBox->isChecked();
|
||||
fMsr2DataParam->recreateDbFile = fRecreateDataFile_checkBox->isChecked();
|
||||
fMsr2DataParam->chainFit = fChainFit_checkBox->isChecked();
|
||||
fMsr2DataParam->openFilesAfterFitting = fOpenFilesAfterFitting_checkBox->isChecked();
|
||||
fMsr2DataParam->titleFromDataFile = fTitleFromData_checkBox->isChecked();
|
||||
fMsr2DataParam->createMsrFileOnly = fCreateMsrFileOnly_checkBox->isChecked();
|
||||
fMsr2DataParam->fitOnly = fFitOnly_checkBox->isChecked();
|
||||
fMsr2DataParam->global = fGlobal_checkBox->isChecked();
|
||||
fMsr2DataParam->globalPlus = fGlobalPlus_checkBox->isChecked();
|
||||
|
||||
return fMsr2DataParam;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when in the 'Run List Input', the 'First' text field is activated. It clears any
|
||||
* entries in 'Run List' and 'Run List File Name'. It furthermore sets the run tag.
|
||||
*
|
||||
* \param str string content of the QTextEdit field.
|
||||
*/
|
||||
void PMsr2DataDialog::runFirstEntered(const QString &str)
|
||||
{
|
||||
|
||||
if (str.length() == 0)
|
||||
return;
|
||||
|
||||
fRunTag = 0;
|
||||
|
||||
if (!fRunList_lineEdit->text().isEmpty())
|
||||
fRunList_lineEdit->clear();
|
||||
if (!fRunListFileName_lineEdit->text().isEmpty())
|
||||
fRunListFileName_lineEdit->clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when in the 'Run List Input', the 'Last' text field is activated. It clears any
|
||||
* entries in 'Run List' and 'Run List File Name'. It furthermore sets the run tag.
|
||||
*
|
||||
* \param str string content of the QTextEdit field.
|
||||
*/
|
||||
void PMsr2DataDialog::runLastEntered(const QString &str)
|
||||
{
|
||||
if (str.length() == 0)
|
||||
return;
|
||||
|
||||
fRunTag = 0;
|
||||
|
||||
if (!fRunList_lineEdit->text().isEmpty())
|
||||
fRunList_lineEdit->clear();
|
||||
if (!fRunListFileName_lineEdit->text().isEmpty())
|
||||
fRunListFileName_lineEdit->clear();
|
||||
|
||||
if (fLast_lineEdit->text().length() == 1)
|
||||
fLast_lineEdit->update();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when in the 'Run List Input', the 'Run List' text field is activated. It clears any
|
||||
* entries in 'First', 'Last', and 'Run List File Name'. It furthermore sets the run tag.
|
||||
*
|
||||
* \param str string content of the QTextEdit field.
|
||||
*/
|
||||
void PMsr2DataDialog::runListEntered(const QString &str)
|
||||
{
|
||||
if (str.length() == 0)
|
||||
return;
|
||||
|
||||
fRunTag = 1;
|
||||
|
||||
if (!fFirst_lineEdit->text().isEmpty())
|
||||
fFirst_lineEdit->clear();
|
||||
if (!fLast_lineEdit->text().isEmpty())
|
||||
fLast_lineEdit->clear();
|
||||
if (!fRunListFileName_lineEdit->text().isEmpty())
|
||||
fRunListFileName_lineEdit->clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when in the 'Run List Input', the 'Run List File Name' text field is activated. It clears any
|
||||
* entries in 'First', 'Last', and 'Run List'. It furthermore sets the run tag.
|
||||
*
|
||||
* \param str string content of the QTextEdit field.
|
||||
*/
|
||||
void PMsr2DataDialog::runListFileNameEntered(const QString &str)
|
||||
{
|
||||
if (str.length() == 0)
|
||||
return;
|
||||
|
||||
fRunTag = 2;
|
||||
|
||||
if (!fFirst_lineEdit->text().isEmpty())
|
||||
fFirst_lineEdit->clear();
|
||||
if (!fLast_lineEdit->text().isEmpty())
|
||||
fLast_lineEdit->clear();
|
||||
if (!fRunList_lineEdit->text().isEmpty())
|
||||
fRunList_lineEdit->clear();
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when in 'Template Run Input', the 'Template Run Number' text field is activated.
|
||||
* It set at the same time the fit-only flag to false.
|
||||
*
|
||||
* \param str string content of the QTextEdit field.
|
||||
*/
|
||||
void PMsr2DataDialog::templateRunEntered(const QString &str)
|
||||
{
|
||||
if (!str.isEmpty())
|
||||
fFitOnly_checkBox->setChecked(false);
|
||||
fTemplateRunNumber_lineEdit->setText(str);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when the 'Create msr-File only' QCheckBox under 'Options' is activated.
|
||||
* Sets at the same time the fit-only flag to false.
|
||||
*
|
||||
* \param buttonState state of the button.
|
||||
*/
|
||||
void PMsr2DataDialog::createMsrFileOnlyChanged(int buttonState)
|
||||
{
|
||||
if (buttonState == Qt::Checked) {
|
||||
fFitOnly_checkBox->setChecked(false);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when the 'Fit Only' QCheckBox under 'Options' is activated.
|
||||
* Sets at the same time the create-msr-file-only and global flags to false. Clears the 'Template Run Number'
|
||||
* field.
|
||||
*
|
||||
* \param buttonState state of the button.
|
||||
*/
|
||||
void PMsr2DataDialog::fitOnlyChanged(int buttonState)
|
||||
{
|
||||
if (buttonState == Qt::Checked) {
|
||||
fCreateMsrFileOnly_checkBox->setChecked(false);
|
||||
fTemplateRunNumber_lineEdit->clear();
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Generates a help content window showing the description for msr2data.
|
||||
*/
|
||||
void PMsr2DataDialog::helpContent()
|
||||
{
|
||||
if (fHelpUrl.isEmpty()) {
|
||||
QMessageBox::information(this, "**INFO**", "Will eventually show a help window");
|
||||
} else {
|
||||
#ifdef _WIN32GCC
|
||||
QMessageBox::information(this, "**INFO**", "If a newer Qt version was available, a help window would be shown!");
|
||||
#else
|
||||
PHelp *help = new PHelp(fHelpUrl);
|
||||
help->show();
|
||||
#endif // _WIN32GCC
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Unchecks global+ if global is checked since global/global+ are excluding options
|
||||
*
|
||||
* \param checked true, if the check-box is checked
|
||||
*/
|
||||
void PMsr2DataDialog::globalOptionSet(bool checked)
|
||||
{
|
||||
if (checked) {
|
||||
if (fGlobalPlus_checkBox->isChecked())
|
||||
fGlobalPlus_checkBox->setChecked(false);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Unchecks global if global+ is checked since global/global+ are excluding options
|
||||
*
|
||||
* \param checked true, if the check-box is checked
|
||||
*/
|
||||
void PMsr2DataDialog::globalPlusOptionSet(bool checked)
|
||||
{
|
||||
if (checked) {
|
||||
if (fGlobal_checkBox->isChecked())
|
||||
fGlobal_checkBox->setChecked(false);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
73
src/musredit_qt5/PMsr2DataDialog.h
Normal file
@ -0,0 +1,73 @@
|
||||
/****************************************************************************
|
||||
|
||||
PMsr2DataDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PMSR2DATADIALOG_H_
|
||||
#define _PMSR2DATADIALOG_H_
|
||||
|
||||
#include <QDialog>
|
||||
#include <QString>
|
||||
|
||||
#include "musredit.h"
|
||||
#include "ui_PMsr2DataDialog.h"
|
||||
|
||||
/**
|
||||
* <p>Class handling the content of the MusrFit/Msr2Data GUI. It collects the input
|
||||
* for B.M. Wojek's msr2data program.
|
||||
*/
|
||||
class PMsr2DataDialog : public QDialog, private Ui::PMsr2DataDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PMsr2DataDialog(PMsr2DataParam *msr2DataParam, const QString helpUrl);
|
||||
|
||||
virtual int getRunTag() { return fRunTag; }
|
||||
virtual PMsr2DataParam* getMsr2DataParam();
|
||||
|
||||
public slots:
|
||||
void runFirstEntered(const QString&);
|
||||
void runLastEntered(const QString&);
|
||||
void runListEntered(const QString&);
|
||||
void runListFileNameEntered(const QString&);
|
||||
void templateRunEntered(const QString&);
|
||||
void createMsrFileOnlyChanged(int);
|
||||
void fitOnlyChanged(int);
|
||||
void helpContent();
|
||||
|
||||
private slots:
|
||||
void globalOptionSet(bool checked);
|
||||
void globalPlusOptionSet(bool checked);
|
||||
|
||||
private:
|
||||
int fRunTag; ///< -1 = not valid, 0 = first last, 1 = run list, 2 = run list file name
|
||||
PMsr2DataParam *fMsr2DataParam; ///< data structure used to handle the necessary input for msr2data.
|
||||
QString fHelpUrl; ///< help url for the Fourier block
|
||||
};
|
||||
|
||||
#endif // _PMSR2DATADIALOG_H_
|
45
src/musredit_qt5/PMusrEditAbout.cpp
Normal file
@ -0,0 +1,45 @@
|
||||
/****************************************************************************
|
||||
|
||||
PMusrEditAbout.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include "PMusrEditAbout.h"
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Handles the musredit about popup.
|
||||
*/
|
||||
PMusrEditAbout::PMusrEditAbout(QWidget *parent, Qt::WindowFlags f) : QDialog(parent, f)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------
|
||||
// END
|
||||
//---------------------------------------------------------------------------
|
46
src/musredit_qt5/PMusrEditAbout.h
Normal file
@ -0,0 +1,46 @@
|
||||
/****************************************************************************
|
||||
|
||||
PMusrEditAbout.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PMUSREDITABOUT_H_
|
||||
#define _PMUSREDITABOUT_H_
|
||||
|
||||
#include "musredit.h"
|
||||
#include "ui_PMusrEditAbout.h"
|
||||
|
||||
class PMusrEditAbout : public QDialog, private Ui::PMusrEditAbout
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PMusrEditAbout(QWidget *parent = 0, Qt::WindowFlags f = 0);
|
||||
virtual ~PMusrEditAbout() {}
|
||||
|
||||
};
|
||||
|
||||
#endif // _PMUSREDITABOUT_H_
|
110
src/musredit_qt5/PPrefsDialog.cpp
Normal file
@ -0,0 +1,110 @@
|
||||
/****************************************************************************
|
||||
|
||||
PPrefsDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include "PPrefsDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param fAdmin keeps all the needed flags
|
||||
*/
|
||||
PPrefsDialog::PPrefsDialog(PAdmin *admin) : fAdmin(admin)
|
||||
{
|
||||
if (!fAdmin)
|
||||
return;
|
||||
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
fKeepMn2Output_checkBox->setChecked(fAdmin->getKeepMinuit2OutputFlag());
|
||||
|
||||
if (fAdmin->getDumpAsciiFlag() && !fAdmin->getDumpRootFlag()) {
|
||||
fDumpAscii_checkBox->setChecked(true);
|
||||
fDumpRoot_checkBox->setChecked(false);
|
||||
} else if (!fAdmin->getDumpAsciiFlag() && fAdmin->getDumpRootFlag()) {
|
||||
fDumpAscii_checkBox->setChecked(false);
|
||||
fDumpRoot_checkBox->setChecked(true);
|
||||
} else {
|
||||
fDumpAscii_checkBox->setChecked(false);
|
||||
fDumpRoot_checkBox->setChecked(false);
|
||||
}
|
||||
|
||||
fTitleFromData_checkBox->setChecked(fAdmin->getTitleFromDataFileFlag());
|
||||
fEnableMusrT0_checkBox->setChecked(fAdmin->getEnableMusrT0Flag());
|
||||
fPerRunBlockChisq_checkBox->setChecked(fAdmin->getChisqPerRunBlockFlag());
|
||||
fEstimateN0_checkBox->setChecked(fAdmin->getEstimateN0Flag());
|
||||
fFourier_checkBox->setChecked(fAdmin->getMusrviewShowFourierFlag());
|
||||
|
||||
fTimeout_lineEdit->setText(QString("%1").arg(fAdmin->getTimeout()));
|
||||
fTimeout_lineEdit->setValidator(new QIntValidator(fTimeout_lineEdit));
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the dump flag (see the '--dump' option of musrfit). 0 == no dump, 1 == ascii dump, 2 == root dump
|
||||
*/
|
||||
int PPrefsDialog::getDump()
|
||||
{
|
||||
int result = 0;
|
||||
|
||||
if (fDumpAscii_checkBox->isChecked())
|
||||
result = 1;
|
||||
else if (fDumpRoot_checkBox->isChecked())
|
||||
result = 2;
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when the QCheckBox 'dump ascii' is selected. Will uncheck 'dump root' since these
|
||||
* two options are mutually exclusive.
|
||||
*/
|
||||
void PPrefsDialog::dumpAscii()
|
||||
{
|
||||
if (fDumpAscii_checkBox->isChecked())
|
||||
fDumpRoot_checkBox->setChecked(false);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called when the QCheckBox 'dump root' is selected. Will uncheck 'dump ascii' since these
|
||||
* two options are mutually exclusive.
|
||||
*/
|
||||
void PPrefsDialog::dumpRoot()
|
||||
{
|
||||
if (fDumpRoot_checkBox->isChecked())
|
||||
fDumpAscii_checkBox->setChecked(false);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
66
src/musredit_qt5/PPrefsDialog.h
Normal file
@ -0,0 +1,66 @@
|
||||
/****************************************************************************
|
||||
|
||||
PPrefsDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PPREFSDIALOG_H_
|
||||
#define _PPREFSDIALOG_H_
|
||||
|
||||
#include <QCheckBox>
|
||||
|
||||
#include <PAdmin.h>
|
||||
|
||||
#include "ui_PPrefsDialog.h"
|
||||
|
||||
/**
|
||||
* <p>Class handling the content of the MusrFit/Preferences.
|
||||
*/
|
||||
class PPrefsDialog : public QDialog, private Ui::PPrefsDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PPrefsDialog(PAdmin *admin);
|
||||
|
||||
bool getMusrviewShowFourierFlag() { return fFourier_checkBox->isChecked(); }
|
||||
bool getKeepMinuit2OutputFlag() { return fKeepMn2Output_checkBox->isChecked(); }
|
||||
bool getTitleFromDataFileFlag() { return fTitleFromData_checkBox->isChecked(); }
|
||||
bool getEnableMusrT0Flag() { return fEnableMusrT0_checkBox->isChecked(); }
|
||||
bool getKeepRunPerBlockChisqFlag() { return fPerRunBlockChisq_checkBox->isChecked(); }
|
||||
bool getEstimateN0Flag() { return fEstimateN0_checkBox->isChecked(); }
|
||||
int getDump();
|
||||
int getTimeout() { return fTimeout_lineEdit->text().toInt(); }
|
||||
|
||||
public slots:
|
||||
void dumpAscii();
|
||||
void dumpRoot();
|
||||
|
||||
private:
|
||||
PAdmin *fAdmin;
|
||||
};
|
||||
|
||||
#endif // _PPREFSDIALOG_H_
|
44
src/musredit_qt5/PReplaceConfirmationDialog.cpp
Normal file
@ -0,0 +1,44 @@
|
||||
/****************************************************************************
|
||||
|
||||
PReplaceConfirmationDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include "PReplaceConfirmationDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param parent pointer to the parent object
|
||||
* \param f qt windows flags
|
||||
*/
|
||||
PReplaceConfirmationDialog::PReplaceConfirmationDialog(QWidget *parent, Qt::WindowFlags f) : QDialog(parent, f)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
}
|
47
src/musredit_qt5/PReplaceConfirmationDialog.h
Normal file
@ -0,0 +1,47 @@
|
||||
/****************************************************************************
|
||||
|
||||
PReplaceConfirmationDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PREPLACECONFIRMATIONDIALOG_H_
|
||||
#define _PREPLACECONFIRMATIONDIALOG_H_
|
||||
|
||||
#include <QDialog>
|
||||
#include <QWidget>
|
||||
|
||||
#include "ui_PReplaceConfirmationDialog.h"
|
||||
|
||||
class PReplaceConfirmationDialog : public QDialog, public Ui::PReplaceConfirmationDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PReplaceConfirmationDialog(QWidget *parent = 0, Qt::WindowFlags f = 0);
|
||||
virtual ~PReplaceConfirmationDialog() {}
|
||||
};
|
||||
|
||||
#endif // _PREPLACECONFIRMATIONDIALOG_H_
|
109
src/musredit_qt5/PReplaceDialog.cpp
Normal file
@ -0,0 +1,109 @@
|
||||
/****************************************************************************
|
||||
|
||||
PReplaceDialog.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QPushButton>
|
||||
#include <QComboBox>
|
||||
#include <QCheckBox>
|
||||
|
||||
#include "PReplaceDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param data find/replace data structure
|
||||
* \param selection if true, find/replace only of the selection
|
||||
* \param parent pointer to the parent object
|
||||
* \param f qt windows flag
|
||||
*/
|
||||
PReplaceDialog::PReplaceDialog(PFindReplaceData *data, const bool selection, QWidget *parent, Qt::WindowFlags f) :
|
||||
QDialog(parent, f), fData(data)
|
||||
{
|
||||
setupUi(this);
|
||||
|
||||
setModal(true);
|
||||
|
||||
// if only empty text, disable find button
|
||||
if (fData->findText == "") {
|
||||
fReplace_pushButton->setEnabled(false);
|
||||
}
|
||||
|
||||
// if there is no selection, disable that option
|
||||
if (!selection) {
|
||||
fSelectedText_checkBox->setChecked(false);
|
||||
fSelectedText_checkBox->setEnabled(false);
|
||||
}
|
||||
|
||||
fFind_comboBox->setItemText(0, fData->findText);
|
||||
fReplacementText_comboBox->setItemText(0, fData->replaceText);
|
||||
fCaseSensitive_checkBox->setChecked(fData->caseSensitive);
|
||||
fWholeWordsOnly_checkBox->setChecked(fData->wholeWordsOnly);
|
||||
fFromCursor_checkBox->setChecked(fData->fromCursor);
|
||||
fFindBackwards_checkBox->setChecked(fData->findBackwards);
|
||||
fPromptOnReplace_checkBox->setChecked(fData->promptOnReplace);
|
||||
|
||||
if (selection) {
|
||||
fSelectedText_checkBox->setChecked(fData->selectedText);
|
||||
}
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>returns the pointer to the find/replace data structure which is updated from the GUI content.
|
||||
*/
|
||||
PFindReplaceData* PReplaceDialog::getData()
|
||||
{
|
||||
fData->findText = fFind_comboBox->currentText();
|
||||
fData->replaceText = fReplacementText_comboBox->currentText();
|
||||
fData->caseSensitive = fCaseSensitive_checkBox->isChecked();
|
||||
fData->wholeWordsOnly = fWholeWordsOnly_checkBox->isChecked();
|
||||
fData->fromCursor = fFromCursor_checkBox->isChecked();
|
||||
fData->findBackwards = fFindBackwards_checkBox->isChecked();
|
||||
if (fSelectedText_checkBox->isEnabled())
|
||||
fData->selectedText = fSelectedText_checkBox->isChecked();
|
||||
fData->promptOnReplace = fPromptOnReplace_checkBox->isChecked();
|
||||
|
||||
return fData;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>SLOT: called on find text available.
|
||||
*/
|
||||
void PReplaceDialog::onFindTextAvailable(const QString&)
|
||||
{
|
||||
if (fFind_comboBox->currentText() != "")
|
||||
fReplace_pushButton->setEnabled(true);
|
||||
else
|
||||
fReplace_pushButton->setEnabled(false);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
53
src/musredit_qt5/PReplaceDialog.h
Normal file
@ -0,0 +1,53 @@
|
||||
/****************************************************************************
|
||||
|
||||
PReplaceDialog.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PREPLACEDIALOG_H_
|
||||
#define _PREPLACEDIALOG_H_
|
||||
|
||||
#include "musredit.h"
|
||||
#include "ui_PReplaceDialog.h"
|
||||
|
||||
class PReplaceDialog : public QDialog, private Ui::PReplaceDialog
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PReplaceDialog(PFindReplaceData *data, const bool selection, QWidget *parent = 0, Qt::WindowFlags f = 0);
|
||||
virtual ~PReplaceDialog() {}
|
||||
|
||||
virtual PFindReplaceData *getData();
|
||||
|
||||
protected slots:
|
||||
virtual void onFindTextAvailable(const QString&);
|
||||
|
||||
private:
|
||||
PFindReplaceData *fData; ///< pointer to the find/replace data
|
||||
};
|
||||
|
||||
#endif // _PREPLACEDIALOG_H_
|
534
src/musredit_qt5/PSubTextEdit.cpp
Normal file
@ -0,0 +1,534 @@
|
||||
/****************************************************************************
|
||||
|
||||
PSubTextEdit.cpp
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include <QAction>
|
||||
#include <QMenu>
|
||||
#include <QDateTime>
|
||||
#include <QLineEdit>
|
||||
#include <QComboBox>
|
||||
#include <QMessageBox>
|
||||
#include <QIcon>
|
||||
#include <QPixmap>
|
||||
#include <QImage>
|
||||
|
||||
#include "PAdmin.h"
|
||||
#include "PSubTextEdit.h"
|
||||
#include "PGetTitleBlockDialog.h"
|
||||
#include "PGetParameterBlockDialog.h"
|
||||
#include "PGetTheoryBlockDialog.h"
|
||||
#include "PGetFunctionsBlockDialog.h"
|
||||
#include "PGetAsymmetryRunBlockDialog.h"
|
||||
#include "PGetSingleHistoRunBlockDialog.h"
|
||||
#include "PGetNonMusrRunBlockDialog.h"
|
||||
#include "PGetFourierBlockDialog.h"
|
||||
#include "PGetPlotBlockDialog.h"
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Constructor.
|
||||
*
|
||||
* \param admin pointer to the musredit internal administration object.
|
||||
* \param parent pointer to the parent object.
|
||||
*/
|
||||
PSubTextEdit::PSubTextEdit(PAdmin *admin, QWidget *parent) :
|
||||
QPlainTextEdit(parent),
|
||||
fAdmin(admin)
|
||||
{
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-title input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertTitle()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetTitleBlockDialog *dlg = new PGetTitleBlockDialog(fAdmin->getHelpUrl("title"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
QString title = dlg->getTitle();
|
||||
insertPlainText(title+"\n");
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-fit-parameter input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertParameterBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetParameterBlockDialog *dlg = new PGetParameterBlockDialog(fAdmin->getHelpUrl("parameters"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
insertPlainText(dlg->getParams());
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Inserts the selected theory item.
|
||||
*
|
||||
* \param name of the theory item to be added.
|
||||
*/
|
||||
void PSubTextEdit::insertTheoryFunction(QString name)
|
||||
{
|
||||
QString str = "????";
|
||||
|
||||
int idx = -1;
|
||||
for (unsigned int i=0; i<fAdmin->getTheoryCounts(); i++) {
|
||||
if (name == fAdmin->getTheoryItem(i)->label) {
|
||||
idx = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if (idx == -1)
|
||||
return;
|
||||
|
||||
PTheory *theoItem = fAdmin->getTheoryItem(idx);
|
||||
if (theoItem == 0)
|
||||
return;
|
||||
|
||||
// add theory function name
|
||||
str = theoItem->name + " ";
|
||||
if (theoItem->name == "userFcn") {
|
||||
str += "libMyLibrary.so TMyFunction ";
|
||||
}
|
||||
|
||||
// add pseudo parameters
|
||||
for (int i=0; i<theoItem->params; i++) {
|
||||
str += QString("%1").arg(i+1) + " ";
|
||||
}
|
||||
|
||||
// add comment
|
||||
str += theoItem->comment;
|
||||
|
||||
// add newline
|
||||
str += "\n";
|
||||
|
||||
insertPlainText(str);
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-theory input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertTheoryBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetTheoryBlockDialog *dlg = new PGetTheoryBlockDialog(fAdmin, fAdmin->getHelpUrl("theory"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
insertPlainText(dlg->getTheoryBlock());
|
||||
insertPlainText("\n");
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-functions input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertFunctionBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetFunctionsBlockDialog *dlg = new PGetFunctionsBlockDialog(fAdmin->getHelpUrl("functions"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
insertPlainText(dlg->getFunctionsBlock());
|
||||
insertPlainText("\n\n");
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-asymmetry-run input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertAsymRunBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetAsymmetryRunBlockDialog *dlg = new PGetAsymmetryRunBlockDialog(fAdmin->getHelpUrl("run"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
QString str, workStr;
|
||||
bool valid = true, present = true;
|
||||
// check if there is already a run block present, necessary because of the '####' line
|
||||
// STILL MISSING
|
||||
|
||||
// add run line
|
||||
str += dlg->getRunHeaderInfo();
|
||||
|
||||
// add fittype
|
||||
str += "fittype 2 (asymmetry fit)\n";
|
||||
|
||||
// add alpha if present
|
||||
workStr = dlg->getAlphaParameter(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
}
|
||||
|
||||
// add beta if present
|
||||
workStr = dlg->getBetaParameter(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
}
|
||||
|
||||
// add map
|
||||
workStr = dlg->getMap(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Given map not valid, will add a default map line",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
str += "map 0 0 0 0 0 0 0 0 0 0\n";
|
||||
}
|
||||
|
||||
// add forward
|
||||
str += dlg->getForward();
|
||||
|
||||
// add backward
|
||||
str += dlg->getBackward();
|
||||
|
||||
// add background or backgr.fix
|
||||
workStr = dlg->getBackground(valid);
|
||||
str += workStr;
|
||||
if (!valid) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Either <b>background</b> or <b>backgr.fix</b> is needed!\nWill set <b>background</b> to 0..10, please correct!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add data
|
||||
workStr = dlg->getData(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Not all Data entries are present.Fix is needed!\nWill not set anything!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add t0 if present
|
||||
workStr = dlg->getT0(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::warning(this, "**ERROR**",
|
||||
"T0's not given, assume that they are present in the data file!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add fit range
|
||||
workStr = dlg->getFitRange(valid);
|
||||
str += workStr;
|
||||
if (!valid) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"No valid fit range is given.Fix is needed!\nWill add a default one!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add packing
|
||||
workStr = dlg->getPacking(present);
|
||||
str += workStr;
|
||||
if (!present) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"No valid packing/binning is given.Fix is needed!\nWill add a default one!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// insert Asymmetry Run Block at the current cursor position
|
||||
insertPlainText(str);
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-single-historgram-run input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertSingleHistRunBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetSingleHistoRunBlockDialog *dlg = new PGetSingleHistoRunBlockDialog(fAdmin->getHelpUrl("run"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
QString str, workStr;
|
||||
bool valid = true, present = true;
|
||||
// check if there is already a run block present, necessary because of the '####' line
|
||||
// STILL MISSING
|
||||
|
||||
// add run line
|
||||
str += dlg->getRunHeaderInfo();
|
||||
|
||||
// add fittype
|
||||
str += "fittype 0 (single histogram fit)\n";
|
||||
|
||||
// add map
|
||||
workStr = dlg->getMap(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Given map not valid, will add a default map line",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
str += "map 0 0 0 0 0 0 0 0 0 0\n";
|
||||
}
|
||||
|
||||
// add forward
|
||||
str += dlg->getForward();
|
||||
|
||||
// add norm
|
||||
str += dlg->getNorm();
|
||||
|
||||
// add lifetime parameter
|
||||
workStr = dlg->getMuonLifetimeParam(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
}
|
||||
|
||||
// add lifetime correction flag if present
|
||||
workStr = dlg->getLifetimeCorrection(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
}
|
||||
|
||||
// add background, backgr.fix or backgr.fit
|
||||
workStr = dlg->getBackground(valid);
|
||||
str += workStr;
|
||||
if (!valid) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Either <b>background</b>, <b>backgr.fix</b>, or <b>backgr.fit</b> is needed!\nWill set <b>background</b> to 0..10, please correct!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add t0 if present
|
||||
workStr = dlg->getT0(present);
|
||||
if (present) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::warning(this, "**ERROR**",
|
||||
"T0's not given, assume that they are present in the data file!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add data
|
||||
workStr = dlg->getData(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Not all Data entries are present.Fix is needed!\nWill not set anything!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add fit range
|
||||
workStr = dlg->getFitRange(valid);
|
||||
str += workStr;
|
||||
if (!valid) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"No valid fit range is given.Fix is needed!\nWill add a default one!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add packing
|
||||
workStr = dlg->getPacking(present);
|
||||
str += workStr;
|
||||
if (!present) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"No valid packing/binning is given.Fix is needed!\nWill add a default one!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// insert Single Histogram Run Block at the current cursor position
|
||||
insertPlainText(str);
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-nonMusr-run input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertNonMusrRunBlock()
|
||||
{
|
||||
PGetNonMusrRunBlockDialog *dlg = new PGetNonMusrRunBlockDialog(fAdmin->getHelpUrl("run"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
QString str, workStr;
|
||||
bool valid = true;
|
||||
// check if there is already a run block present, necessary because of the '####' line
|
||||
// STILL MISSING
|
||||
|
||||
// add run line
|
||||
str += dlg->getRunHeaderInfo();
|
||||
|
||||
// add fittype
|
||||
str += "fittype 8 (non musr fit)\n";
|
||||
|
||||
// add map
|
||||
workStr = dlg->getMap(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Given map not valid, will add a default map line",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
str += "map 0 0 0 0 0 0 0 0 0 0\n";
|
||||
}
|
||||
|
||||
// add xy-data
|
||||
workStr = dlg->getXYData(valid);
|
||||
if (valid) {
|
||||
str += workStr;
|
||||
} else {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"Not all xy-data entries are present.Fix is needed!\nWill not set anything!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add fit range
|
||||
workStr = dlg->getFitRange(valid);
|
||||
str += workStr;
|
||||
if (!valid) {
|
||||
QMessageBox::critical(this, "**ERROR**",
|
||||
"No valid fit range is given.Fix is needed!\nWill add a default one!",
|
||||
QMessageBox::Ok, QMessageBox::NoButton);
|
||||
}
|
||||
|
||||
// add packing
|
||||
str += "packing 1\n";
|
||||
|
||||
// insert NonMusr Run Block at the current cursor position
|
||||
insertPlainText(str);
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Insert the command block.
|
||||
*/
|
||||
void PSubTextEdit::insertCommandBlock()
|
||||
{
|
||||
insertPlainText("###############################################################\n");
|
||||
insertPlainText("COMMANDS\n");
|
||||
insertPlainText("SET BATCH\n");
|
||||
insertPlainText("STRATEGY 1\n");
|
||||
insertPlainText("MINIMIZE\n");
|
||||
insertPlainText("#MINOS\n");
|
||||
insertPlainText("SAVE\n");
|
||||
insertPlainText("END RETURN\n\n");
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-Fourier input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertFourierBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetFourierBlockDialog *dlg = new PGetFourierBlockDialog(fAdmin->getHelpUrl("fourier"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
insertPlainText(dlg->getFourierBlock()+"\n");
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Starts the msr-plot input dialog window.
|
||||
*/
|
||||
void PSubTextEdit::insertPlotBlock()
|
||||
{
|
||||
// for the time being the url's are hard coded but should be transfered to the XML startup
|
||||
PGetPlotBlockDialog *dlg = new PGetPlotBlockDialog(fAdmin->getHelpUrl("plot"));
|
||||
|
||||
if (dlg == 0)
|
||||
return;
|
||||
|
||||
if (dlg->exec() == QDialog::Accepted) {
|
||||
insertPlainText(dlg->getPlotBlock()+"\n");
|
||||
}
|
||||
|
||||
delete dlg;
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Insert a default msr-statistics block.
|
||||
*/
|
||||
void PSubTextEdit::insertStatisticBlock()
|
||||
{
|
||||
QDateTime dt = QDateTime::currentDateTime();
|
||||
insertPlainText("###############################################################\n");
|
||||
insertPlainText("STATISTIC --- " + dt.toString("yyyy-MM-dd hh:mm:ss") + "\n");
|
||||
insertPlainText("chisq = ????, NDF = ????, chisq/NDF = ????\n\n");
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------
|
||||
// END
|
||||
//----------------------------------------------------------------------------------------------------
|
68
src/musredit_qt5/PSubTextEdit.h
Normal file
@ -0,0 +1,68 @@
|
||||
/****************************************************************************
|
||||
|
||||
PSubTextEdit.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2009-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PSUBTEXTEDIT_H_
|
||||
#define _PSUBTEXTEDIT_H_
|
||||
|
||||
#include <QPlainTextEdit>
|
||||
#include <QDateTime>
|
||||
|
||||
#include "PAdmin.h"
|
||||
|
||||
//------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Class handling a single text edit tab within musredit.
|
||||
*/
|
||||
class PSubTextEdit : public QPlainTextEdit
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PSubTextEdit(PAdmin *admin = 0, QWidget *parent = 0);
|
||||
virtual ~PSubTextEdit() {}
|
||||
|
||||
public slots:
|
||||
void insertTitle();
|
||||
void insertParameterBlock();
|
||||
void insertTheoryFunction(QString name);
|
||||
void insertTheoryBlock();
|
||||
void insertFunctionBlock();
|
||||
void insertAsymRunBlock();
|
||||
void insertSingleHistRunBlock();
|
||||
void insertNonMusrRunBlock();
|
||||
void insertCommandBlock();
|
||||
void insertFourierBlock();
|
||||
void insertPlotBlock();
|
||||
void insertStatisticBlock();
|
||||
|
||||
private:
|
||||
PAdmin *fAdmin; ///< pointer to the administration object which holds working-, executable-paths etc.
|
||||
};
|
||||
|
||||
#endif // _PSUBTEXTEDIT_H_
|
2637
src/musredit_qt5/PTextEdit.cpp
Normal file
182
src/musredit_qt5/PTextEdit.h
Normal file
@ -0,0 +1,182 @@
|
||||
/****************************************************************************
|
||||
|
||||
PTextEdit.h
|
||||
|
||||
Author: Andreas Suter
|
||||
e-mail: andreas.suter@psi.ch
|
||||
|
||||
*****************************************************************************/
|
||||
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2010-2014 by Andreas Suter *
|
||||
* andreas.suter@psi.ch *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License as published by *
|
||||
* the Free Software Foundation; either version 2 of the License, or *
|
||||
* (at your option) any later version. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#ifndef _PTEXTEDIT_H_
|
||||
#define _PTEXTEDIT_H_
|
||||
|
||||
#include <QMainWindow>
|
||||
#include <QMap>
|
||||
#include <QTimer>
|
||||
#include <QString>
|
||||
#include <QVector>
|
||||
|
||||
#include <QtDebug>
|
||||
|
||||
|
||||
#include "musredit.h"
|
||||
|
||||
class PSubTextEdit;
|
||||
class PAdmin;
|
||||
class QFileSystemWatcher;
|
||||
class QAction;
|
||||
class QComboBox;
|
||||
class QTabWidget;
|
||||
class QTextEdit;
|
||||
class QMenu;
|
||||
|
||||
//----------------------------------------------------------------------------------------------
|
||||
/**
|
||||
* <p>Main class for musredit.
|
||||
*/
|
||||
class PTextEdit : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
PTextEdit( QWidget *parent = 0, Qt::WindowFlags f = 0 );
|
||||
virtual ~PTextEdit() {}
|
||||
|
||||
public slots:
|
||||
void aboutToQuit();
|
||||
|
||||
signals:
|
||||
void close();
|
||||
|
||||
private:
|
||||
void setupFileActions();
|
||||
void setupEditActions();
|
||||
void setupTextActions();
|
||||
void setupMusrActions();
|
||||
void setupHelpActions();
|
||||
void load( const QString &f, const int index=-1 );
|
||||
PSubTextEdit *currentEditor() const;
|
||||
void doConnections( PSubTextEdit *e );
|
||||
bool validRunList(const QString runList);
|
||||
void fileSystemWatcherActivation();
|
||||
|
||||
private slots:
|
||||
void insertTitle();
|
||||
void insertParameterBlock();
|
||||
void insertTheoryBlock();
|
||||
void insertTheoryFunction(QAction *a);
|
||||
void insertFunctionBlock();
|
||||
void insertAsymRunBlock();
|
||||
void insertSingleHistRunBlock();
|
||||
void insertNonMusrRunBlock();
|
||||
void insertCommandBlock();
|
||||
void insertFourierBlock();
|
||||
void insertPlotBlock();
|
||||
void insertStatisticBlock();
|
||||
|
||||
void fileNew();
|
||||
void fileOpen();
|
||||
void fileOpenRecent();
|
||||
void fileReload();
|
||||
void fileOpenPrefs();
|
||||
void fileSave();
|
||||
void fileSaveAs();
|
||||
void fileSavePrefs();
|
||||
void filePrint();
|
||||
void fileClose( const bool check = true );
|
||||
void fileCloseAll();
|
||||
void fileCloseAllOthers();
|
||||
void fileExit();
|
||||
|
||||
void editUndo();
|
||||
void editRedo();
|
||||
void editSelectAll();
|
||||
void editCut();
|
||||
void editCopy();
|
||||
void editPaste();
|
||||
void editFind();
|
||||
void editFindNext();
|
||||
void editFindPrevious();
|
||||
void editFindAndReplace();
|
||||
void editComment();
|
||||
void editUncomment();
|
||||
|
||||
void textFamily( const QString &f );
|
||||
void textSize( const QString &p );
|
||||
|
||||
void musrGetAsymmetryDefault();
|
||||
void musrGetSingleHistoDefault();
|
||||
void musrCalcChisq();
|
||||
void musrFit();
|
||||
void musrMsr2Data();
|
||||
void musrView();
|
||||
void musrT0();
|
||||
void musrFT();
|
||||
void musrPrefs();
|
||||
void musrSwapMsrMlog();
|
||||
void musrDump();
|
||||
|
||||
void helpContents();
|
||||
void helpAboutQt();
|
||||
void helpAbout();
|
||||
|
||||
void fontChanged( const QFont &f );
|
||||
void textChanged(const bool forced = false);
|
||||
void currentCursorPosition();
|
||||
|
||||
void replace();
|
||||
void replaceAndClose();
|
||||
void replaceAll();
|
||||
|
||||
void applyFontSettings(QWidget*);
|
||||
void fileChanged(const QString &fileName);
|
||||
void setFileSystemWatcherActive();
|
||||
|
||||
private:
|
||||
PAdmin *fAdmin; ///< pointer to the xml-startup file informations. Needed for different purposes like default working- and executable directories etc.
|
||||
QFileSystemWatcher *fFileSystemWatcher; ///< checks if msr-files are changing on the disk while being open in musredit.
|
||||
bool fFileSystemWatcherActive; ///< flag to enable/disable the file system watcher
|
||||
QTimer fFileSystemWatcherTimeout; ///< timer used to re-enable file system watcher. Needed to delay the re-enabling
|
||||
QString fLastDirInUse; ///< string holding the path from where the last file was loaded.
|
||||
QStringList fMusrFTPrevCmd;
|
||||
|
||||
QAction *fMusrT0Action;
|
||||
|
||||
PMsr2DataParam *fMsr2DataParam; ///< structure holding the necessary input information for msr2data
|
||||
PFindReplaceData *fFindReplaceData; ///< structure holding the ncessary input for find/replace
|
||||
|
||||
QComboBox *fComboFont; ///< combo box for the font selector
|
||||
QComboBox *fComboSize; ///< combo box for the font size
|
||||
bool fFontChanging; ///< flag needed to prevent some textChanged feature to occure when only the font changed
|
||||
|
||||
QTabWidget *fTabWidget; ///< tab widget in which the text editor(s) are placed
|
||||
QMap<PSubTextEdit*, QString> fFilenames; ///< mapper between tab widget object and filename
|
||||
|
||||
QMenu *fRecentFilesMenu; ///< recent file menu
|
||||
QAction *fRecentFilesAction[MAX_RECENT_FILES]; ///< array of the recent file actions
|
||||
|
||||
void fillRecentFiles();
|
||||
};
|
||||
|
||||
|
||||
#endif // _PTEXTEDIT_H_
|
10
src/musredit_qt5/README
Normal file
@ -0,0 +1,10 @@
|
||||
#---------------------------------------------------------------------
|
||||
# README
|
||||
# Andreas Suter, 2015/10/26
|
||||
#---------------------------------------------------------------------
|
||||
|
||||
musredit_qt5 requires Qt 5.4.x or newer.
|
||||
|
||||
#---------------------------------------------------------------------
|
||||
# this is the end ...
|
||||
#---------------------------------------------------------------------
|
215
src/musredit_qt5/forms/PFindDialog.ui
Normal file
@ -0,0 +1,215 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PFindDialog</class>
|
||||
<widget class="QDialog" name="PFindDialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>349</width>
|
||||
<height>271</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Find Text - musredit</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>342</width>
|
||||
<height>264</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QGroupBox" name="fFind_groupBox">
|
||||
<property name="title">
|
||||
<string>Find</string>
|
||||
</property>
|
||||
<layout class="QFormLayout" name="formLayout_2">
|
||||
<item row="0" column="0" colspan="2">
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFind_label">
|
||||
<property name="text">
|
||||
<string>Text to find:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fFind_comboBox">
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QGroupBox" name="fOptions_groupBox">
|
||||
<property name="title">
|
||||
<string>Options</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
|
||||
</property>
|
||||
<layout class="QFormLayout" name="formLayout">
|
||||
<item row="0" column="0" colspan="2">
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="0" column="0">
|
||||
<widget class="QCheckBox" name="fCaseSensitive_checkBox">
|
||||
<property name="text">
|
||||
<string>C&ase Sensitive</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QCheckBox" name="fFindBackwards_checkBox">
|
||||
<property name="text">
|
||||
<string>Find &backwards</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QCheckBox" name="fWholeWordsOnly_checkBox">
|
||||
<property name="text">
|
||||
<string>&Whole words only</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QCheckBox" name="fSelectedText_checkBox">
|
||||
<property name="text">
|
||||
<string>&Selected text</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QCheckBox" name="fFromCursor_checkBox">
|
||||
<property name="text">
|
||||
<string>From c&ursor</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>168</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fFind_pushButton">
|
||||
<property name="text">
|
||||
<string>&Find</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fClose_pushButton">
|
||||
<property name="text">
|
||||
<string>&Close</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fFind_comboBox</tabstop>
|
||||
<tabstop>fCaseSensitive_checkBox</tabstop>
|
||||
<tabstop>fWholeWordsOnly_checkBox</tabstop>
|
||||
<tabstop>fFromCursor_checkBox</tabstop>
|
||||
<tabstop>fFindBackwards_checkBox</tabstop>
|
||||
<tabstop>fSelectedText_checkBox</tabstop>
|
||||
<tabstop>fFind_pushButton</tabstop>
|
||||
<tabstop>fClose_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fClose_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PFindDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>287</x>
|
||||
<y>205</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>344</x>
|
||||
<y>228</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFind_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PFindDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>208</x>
|
||||
<y>211</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>171</x>
|
||||
<y>211</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFind_comboBox</sender>
|
||||
<signal>editTextChanged(QString)</signal>
|
||||
<receiver>PFindDialog</receiver>
|
||||
<slot>onFindTextAvailable(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>126</x>
|
||||
<y>58</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>105</x>
|
||||
<y>218</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>onFindTextAvailable(QString)</slot>
|
||||
</slots>
|
||||
</ui>
|
707
src/musredit_qt5/forms/PGetAsymmetryRunBlockDialog.ui
Normal file
@ -0,0 +1,707 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetAsymmetryRunBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetAsymmetryRunBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>462</width>
|
||||
<height>506</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Asymmetry Run Block Parameters</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fRunHeaderInfo_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>0</y>
|
||||
<width>441</width>
|
||||
<height>121</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Run Header Info</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fRunFileName_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>91</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Run File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBeamline_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>71</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Beamline</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fInstitute_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>90</y>
|
||||
<width>56</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Institute</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFileFormat_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>260</x>
|
||||
<y>90</y>
|
||||
<width>91</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>File Format</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fRunFileName_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>26</y>
|
||||
<width>311</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBeamline_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>56</y>
|
||||
<width>113</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fInstitute_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>86</y>
|
||||
<width>77</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>RAL</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>TRIUMF</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>JPARC</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fFileFormat_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>336</x>
|
||||
<y>86</y>
|
||||
<width>91</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>NeXuS</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-NPP</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-PPC</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI-BIN</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI-MDU</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MUD</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MDU-ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>DB</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fRequiredEntries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>120</y>
|
||||
<width>441</width>
|
||||
<height>241</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Required Entries</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fMap_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>56</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Map</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fForwardHistoNo_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Forward Histo No</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackwardHistoNo_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>240</x>
|
||||
<y>60</y>
|
||||
<width>121</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Backward Histo No</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fDataRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>90</y>
|
||||
<width>81</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Data Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackgroundFix_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>120</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Fix</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fOr_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>310</x>
|
||||
<y>120</y>
|
||||
<width>31</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OR</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackgroundRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>150</y>
|
||||
<width>121</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFitRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>180</y>
|
||||
<width>71</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Fit Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fMap_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>60</x>
|
||||
<y>26</y>
|
||||
<width>371</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>0 0 0 0 0 0 0 0 0</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fForwardHistoNo_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackwardHistoNo_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>360</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataForwardStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>86</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataForwardEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>86</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataBackwardStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>290</x>
|
||||
<y>86</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataBackwardEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>360</x>
|
||||
<y>86</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundForwardFix_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>116</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundBackwardFix_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>116</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundForwardStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>146</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundForwardEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>146</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundBackwardStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>290</x>
|
||||
<y>146</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundBackwardEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>360</x>
|
||||
<y>146</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fFitRangeStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>176</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fFitRangeEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>176</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fPacking_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>206</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>1</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fPacking_textLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>210</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Packing/Binning</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fOptionalEntries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>360</y>
|
||||
<width>441</width>
|
||||
<height>91</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Optional Entries</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fAplha_textLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>131</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Alpha (default = 1.0)</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBeta_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>240</x>
|
||||
<y>30</y>
|
||||
<width>121</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Beta (default = 1.0)</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fT0_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>241</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>t0 (reqired if not given in the data file)</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fAlpha_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>26</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBeta_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>360</x>
|
||||
<y>26</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string/>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fT0Forward_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>290</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fT0Backward_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>360</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>460</y>
|
||||
<width>441</width>
|
||||
<height>39</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>188</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetAsymmetryRunBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>458</x>
|
||||
<y>434</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>471</x>
|
||||
<y>415</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetAsymmetryRunBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>394</x>
|
||||
<y>438</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>407</x>
|
||||
<y>406</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetAsymmetryRunBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>47</x>
|
||||
<y>437</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>70</x>
|
||||
<y>398</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
291
src/musredit_qt5/forms/PGetDefaultDialog.ui
Normal file
@ -0,0 +1,291 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetDefaultDialog</class>
|
||||
<widget class="QDialog" name="PGetDefaultDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>400</width>
|
||||
<height>168</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Run</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>130</y>
|
||||
<width>381</width>
|
||||
<height>27</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>12</x>
|
||||
<y>12</y>
|
||||
<width>84</width>
|
||||
<height>111</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="fRunFileName_label">
|
||||
<property name="text">
|
||||
<string>Run File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fBeamline_label">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>68</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Beamline</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fInstitute_label">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>68</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Institute</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fFileFormat_label">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>68</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>File Format</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>99</x>
|
||||
<y>12</y>
|
||||
<width>291</width>
|
||||
<height>111</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fRunFileName_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fBeamline_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fInstitute_comboBox">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>80</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>RAL</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>TRIUMF</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>JPARC</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fFileFormat_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>NeXuS</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-NPP</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-PPC</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI-BIN</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MDU</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MDU-ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MUD</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>WKM</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>DB</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetDefaultDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>337</x>
|
||||
<y>272</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>355</x>
|
||||
<y>225</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetDefaultDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>286</x>
|
||||
<y>265</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>243</x>
|
||||
<y>227</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetDefaultDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>50</x>
|
||||
<y>273</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>115</x>
|
||||
<y>221</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
399
src/musredit_qt5/forms/PGetFourierBlockDialog.ui
Normal file
@ -0,0 +1,399 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetFourierBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetFourierBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>367</width>
|
||||
<height>269</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Fourier</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>230</y>
|
||||
<width>351</width>
|
||||
<height>32</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fUnits_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>61</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Units</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFourierPower_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>45</y>
|
||||
<width>91</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Fourier Power</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fApodization_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>75</y>
|
||||
<width>141</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Apodization</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fPlot_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>110</y>
|
||||
<width>61</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Plot</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fPhase_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>140</y>
|
||||
<width>61</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Phase</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fPhaseCorrectionRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>160</y>
|
||||
<width>111</width>
|
||||
<height>41</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;">
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:8pt;">Phase Correction</span></p>
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:8pt;">Range</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>200</y>
|
||||
<width>61</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fUnits_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>5</y>
|
||||
<width>111</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Gauss</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Tesla</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MHz</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Mc/s</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fFourierPower_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>40</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fApodization_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>70</y>
|
||||
<width>111</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>None</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Weak</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Medium</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Strong</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fPlot_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>105</y>
|
||||
<width>111</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Power</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Real</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Imag</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Real & Imag</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Phase</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fPhase_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>140</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fPhaseCorrectionRangeLow_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>170</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fPhaseCorrectionRangeUp_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>250</x>
|
||||
<y>170</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fRangeLow_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>130</x>
|
||||
<y>200</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fRangeUp_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>250</x>
|
||||
<y>200</y>
|
||||
<width>113</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFourierBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>337</x>
|
||||
<y>272</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>355</x>
|
||||
<y>225</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFourierBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>286</x>
|
||||
<y>265</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>243</x>
|
||||
<y>227</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFourierBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>50</x>
|
||||
<y>273</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>115</x>
|
||||
<y>221</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFourierBlockDialog</receiver>
|
||||
<slot>fillFourierBlock()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>247</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>175</x>
|
||||
<y>264</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>fillFourierBlock()</slot>
|
||||
</slots>
|
||||
</ui>
|
259
src/musredit_qt5/forms/PGetFunctionsBlockDialog.ui
Normal file
@ -0,0 +1,259 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetFunctionsBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetFunctionsBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>636</width>
|
||||
<height>604</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Functions</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>570</y>
|
||||
<width>631</width>
|
||||
<height>32</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QTextEdit" name="fHelp_textEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>10</y>
|
||||
<width>631</width>
|
||||
<height>201</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="html">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
|
||||
<table style="-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;">
|
||||
<tr>
|
||||
<td style="border: none;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">Supported basic arithmetics: </span><span style=" font-family:'Courier New,courier'; font-size:10pt;">+, -, *, /, ()</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">Supported built-in functions; </span><span style=" font-family:'Courier New,courier'; font-size:10pt;">cos(), sin(), tan(), acos(), asin(), atan(), cosh(), sinh(), tanh(), acosh(), asinh(), atanh(), exp(), log(), ln()</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">Supported pre-defined constants</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New,courier'; font-size:10pt;">gamma_mu = 0.0135538817 (MHz/G)</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New,courier'; font-size:10pt;">pi = 3.1415926535897932846</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">Parameters and Maps are reached via parX, mapY, where X, Y are numbers, e.g. par1, map3</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Lucida Grande'; font-size:10pt;">Examples:</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New,courier'; font-size:10pt;">fun1 = gamma_mu * par3</span><span style=" font-family:'Lucida Grande'; font-size:10pt;"> valid</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New,courier'; font-size:10pt;">fun2 = par2/map4 * sin(par3*par5)</span><span style=" font-family:'Lucida Grande'; font-size:10pt;"> valid</span></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-family:'Courier New,courier'; font-size:10pt;">fun3 = fun1 + par6</span><span style=" font-family:'Lucida Grande'; font-size:10pt;"> invalid, since functions cannot be used with the functions definition</span></p></td></tr></table></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fInput_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>210</y>
|
||||
<width>631</width>
|
||||
<height>101</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Input</string>
|
||||
</property>
|
||||
<widget class="QLineEdit" name="fFunctionInput_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>90</x>
|
||||
<y>30</y>
|
||||
<width>521</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFunction_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>71</width>
|
||||
<height>17</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Function:</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fAdd_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>500</x>
|
||||
<y>60</y>
|
||||
<width>113</width>
|
||||
<height>32</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Add</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QPlainTextEdit" name="fFunctionBlock_plainTextEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>310</y>
|
||||
<width>631</width>
|
||||
<height>251</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string>#####################################################
|
||||
FUNCTIONS</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFunctionsBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>629</x>
|
||||
<y>584</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>368</x>
|
||||
<y>565</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFunctionsBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>538</x>
|
||||
<y>577</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>265</x>
|
||||
<y>583</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFunctionsBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>41</x>
|
||||
<y>585</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>111</x>
|
||||
<y>582</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fAdd_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetFunctionsBlockDialog</receiver>
|
||||
<slot>addFunction()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>555</x>
|
||||
<y>289</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>410</x>
|
||||
<y>591</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFunctionInput_lineEdit</sender>
|
||||
<signal>returnPressed()</signal>
|
||||
<receiver>PGetFunctionsBlockDialog</receiver>
|
||||
<slot>addFunction()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>399</x>
|
||||
<y>252</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>413</x>
|
||||
<y>570</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>addFunction()</slot>
|
||||
</slots>
|
||||
</ui>
|
863
src/musredit_qt5/forms/PGetMusrFTOptionsDialog.ui
Normal file
@ -0,0 +1,863 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetMusrFTOptionsDialog</class>
|
||||
<widget class="QDialog" name="PGetMusrFTOptionsDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>711</width>
|
||||
<height>650</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>musrFT Options</string>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fFourier_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>400</y>
|
||||
<width>671</width>
|
||||
<height>201</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string> Fourier </string>
|
||||
</property>
|
||||
<widget class="QWidget" name="">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>21</x>
|
||||
<y>31</y>
|
||||
<width>641</width>
|
||||
<height>156</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_22">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_13">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierOptions_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Options</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fFourierOption_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>UnDef</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>real</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>imag</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>real+imag</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>power</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>phase</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_6">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>218</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_14">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierUnits_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Units</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fFourierUnits_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>UnDef</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Gauss</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Tesla</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MHz</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Mc/s</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_23">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_19">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierPower_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Power</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFourierPower_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>88</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_17">
|
||||
<item>
|
||||
<widget class="QLabel" name="fLifetimeCorrection_label">
|
||||
<property name="text">
|
||||
<string>Lifetime Correction</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fLifetimeCorrection_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_20">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierRange_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Range</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_16">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierRangeStart_label">
|
||||
<property name="text">
|
||||
<string>Start</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFourierRangeStart_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_15">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierRangeEnd_label">
|
||||
<property name="text">
|
||||
<string>End</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFourierRangeEnd_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_18">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fAveragedView_checkBox">
|
||||
<property name="text">
|
||||
<string>Average All</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fAveragePerDataSet_checkBox">
|
||||
<property name="text">
|
||||
<string>Average per Data Set</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_7">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>88</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fCreateMsrFile_checkBox">
|
||||
<property name="text">
|
||||
<string>Create msr-File</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_21">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFourierTitle_label">
|
||||
<property name="text">
|
||||
<string>Title</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFourierTitle_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fHistoInfo_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>160</y>
|
||||
<width>671</width>
|
||||
<height>231</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string> Histo Info </string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>641</width>
|
||||
<height>188</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QLabel" name="fBkgRange_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Range (in Bins)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="fBkgStartBin_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">StartBin</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fBkgRangeStartBin_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="fBkgEndBin_label">
|
||||
<property name="text">
|
||||
<string>EndBin:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fBkgRangeEndBin_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<widget class="QLabel" name="fBkgList_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Background List</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fBkgList_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_7">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
||||
<item>
|
||||
<widget class="QLabel" name="fApodization_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"><span style=" font-weight:600;">Apodization</span></p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fApodization_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>none</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>weak</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>medium</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>strong</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||
<item>
|
||||
<widget class="QLabel" name="fPacking_label">
|
||||
<property name="text">
|
||||
<string>Packing</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fPacking_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>168</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_10">
|
||||
<item>
|
||||
<widget class="QLabel" name="fTimeRange_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Time Range (usec)</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_9">
|
||||
<item>
|
||||
<widget class="QLabel" name="fTimeRangeStart_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Start</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fTimeRangeStart_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_8">
|
||||
<item>
|
||||
<widget class="QLabel" name="fTimeRangeEnd_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">End</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fTimeRangeEnd_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_11">
|
||||
<item>
|
||||
<widget class="QLabel" name="fHistoList_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Histo List</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fHistoList_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_12">
|
||||
<item>
|
||||
<widget class="QLabel" name="fT0_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:600; font-style:normal;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">T0's</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fT0_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fFileSelection_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>10</y>
|
||||
<width>671</width>
|
||||
<height>141</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>File Selection</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>19</x>
|
||||
<y>31</y>
|
||||
<width>641</width>
|
||||
<height>96</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_27">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fCurrentMsrFile_checkBox">
|
||||
<property name="text">
|
||||
<string>Current msr-File</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fAllMsrFiles_checkBox">
|
||||
<property name="text">
|
||||
<string>ALL msr-Files</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_8">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>318</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_25">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fMsrFileSelector_pushButton">
|
||||
<property name="text">
|
||||
<string>Select msr-File(s)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fMsrFileSelector_lineEdit">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fMsrFileNameClear_pushButton">
|
||||
<property name="toolTip">
|
||||
<string>clear msr-file name list</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Clear</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_26">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fDataFileSelector_pushButton">
|
||||
<property name="text">
|
||||
<string>Select data-File(s)</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fDataFileSelector_lineEdit">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>23</height>
|
||||
</size>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fDataFileNameClear_pushButton">
|
||||
<property name="toolTip">
|
||||
<string>clear data-file name list</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Clear</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>610</y>
|
||||
<width>671</width>
|
||||
<height>29</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_24">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_4">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>78</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fResetAll_pushButton">
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Reset All</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_9">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="standardButtons">
|
||||
<set>QDialogButtonBox::Cancel|QDialogButtonBox::Ok</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fCurrentMsrFile_checkBox</tabstop>
|
||||
<tabstop>fAllMsrFiles_checkBox</tabstop>
|
||||
<tabstop>fMsrFileSelector_pushButton</tabstop>
|
||||
<tabstop>fMsrFileSelector_lineEdit</tabstop>
|
||||
<tabstop>fMsrFileNameClear_pushButton</tabstop>
|
||||
<tabstop>fDataFileSelector_pushButton</tabstop>
|
||||
<tabstop>fDataFileSelector_lineEdit</tabstop>
|
||||
<tabstop>fDataFileNameClear_pushButton</tabstop>
|
||||
<tabstop>fBkgRangeStartBin_lineEdit</tabstop>
|
||||
<tabstop>fBkgRangeEndBin_lineEdit</tabstop>
|
||||
<tabstop>fBkgList_lineEdit</tabstop>
|
||||
<tabstop>fApodization_comboBox</tabstop>
|
||||
<tabstop>fPacking_lineEdit</tabstop>
|
||||
<tabstop>fTimeRangeStart_lineEdit</tabstop>
|
||||
<tabstop>fTimeRangeEnd_lineEdit</tabstop>
|
||||
<tabstop>fHistoList_lineEdit</tabstop>
|
||||
<tabstop>fT0_lineEdit</tabstop>
|
||||
<tabstop>fFourierOption_comboBox</tabstop>
|
||||
<tabstop>fFourierUnits_comboBox</tabstop>
|
||||
<tabstop>fFourierPower_lineEdit</tabstop>
|
||||
<tabstop>fLifetimeCorrection_lineEdit</tabstop>
|
||||
<tabstop>fFourierRangeStart_lineEdit</tabstop>
|
||||
<tabstop>fFourierRangeEnd_lineEdit</tabstop>
|
||||
<tabstop>fAveragedView_checkBox</tabstop>
|
||||
<tabstop>fCreateMsrFile_checkBox</tabstop>
|
||||
<tabstop>fFourierTitle_lineEdit</tabstop>
|
||||
<tabstop>fResetAll_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
<tabstop>buttonBox</tabstop>
|
||||
</tabstops>
|
||||
<resources/>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>accepted()</signal>
|
||||
<receiver>PGetMusrFTOptionsDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>683</x>
|
||||
<y>611</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>157</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>rejected()</signal>
|
||||
<receiver>PGetMusrFTOptionsDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>689</x>
|
||||
<y>611</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
<y>274</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetMusrFTOptionsDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>85</x>
|
||||
<y>627</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>147</x>
|
||||
<y>624</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
465
src/musredit_qt5/forms/PGetNonMusrRunBlockDialog.ui
Normal file
@ -0,0 +1,465 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetNonMusrRunBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetNonMusrRunBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>419</width>
|
||||
<height>307</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get NonMusr Run Block Parameters</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fRunHeaderInfo_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>0</y>
|
||||
<width>401</width>
|
||||
<height>131</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Run Header Info</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>381</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="fRunFileName_label">
|
||||
<property name="text">
|
||||
<string>Run File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fRunFileName_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>11</x>
|
||||
<y>60</y>
|
||||
<width>381</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QLabel" name="fBeamline_label">
|
||||
<property name="text">
|
||||
<string>Beamline</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Fixed</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>23</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fBeamline_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>91</y>
|
||||
<width>381</width>
|
||||
<height>27</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<widget class="QLabel" name="fInstitute_label">
|
||||
<property name="text">
|
||||
<string>Institute</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<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>34</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fInstitute_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>RAL</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>TRIUMF</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>JPARC</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_5">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fFileFormat_label">
|
||||
<property name="text">
|
||||
<string>File Format</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="fFileFormat_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>DB</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fReqiredEntries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>130</y>
|
||||
<width>401</width>
|
||||
<height>131</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Required Entries</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>381</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||
<item>
|
||||
<widget class="QLabel" name="fMap_label">
|
||||
<property name="text">
|
||||
<string>Map</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fMap_lineEdit">
|
||||
<property name="text">
|
||||
<string>0 0 0 0 0 0 0 0 0 0</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>11</x>
|
||||
<y>60</y>
|
||||
<width>281</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
||||
<item>
|
||||
<widget class="QLabel" name="fXYData_label">
|
||||
<property name="text">
|
||||
<string>xy-Data</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_6">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>37</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fXData_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fYData_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>92</y>
|
||||
<width>291</width>
|
||||
<height>28</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_7">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFitRange_label">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Fit Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFitRangeStart_lineEdit">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>105</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>105</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFitRangeEnd_lineEdit">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>105</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>105</width>
|
||||
<height>16777215</height>
|
||||
</size>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>270</y>
|
||||
<width>401</width>
|
||||
<height>27</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fRunFileName_lineEdit</tabstop>
|
||||
<tabstop>fBeamline_lineEdit</tabstop>
|
||||
<tabstop>fInstitute_comboBox</tabstop>
|
||||
<tabstop>fFileFormat_comboBox</tabstop>
|
||||
<tabstop>fMap_lineEdit</tabstop>
|
||||
<tabstop>fXData_lineEdit</tabstop>
|
||||
<tabstop>fYData_lineEdit</tabstop>
|
||||
<tabstop>fFitRangeStart_lineEdit</tabstop>
|
||||
<tabstop>fFitRangeEnd_lineEdit</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetNonMusrRunBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>337</x>
|
||||
<y>281</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>364</x>
|
||||
<y>216</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetNonMusrRunBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>289</x>
|
||||
<y>277</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>238</x>
|
||||
<y>220</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetNonMusrRunBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>37</x>
|
||||
<y>286</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>78</x>
|
||||
<y>229</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
347
src/musredit_qt5/forms/PGetParameterBlockDialog.ui
Normal file
@ -0,0 +1,347 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetParameterBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetParameterBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>656</width>
|
||||
<height>476</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Parameter</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>430</y>
|
||||
<width>631</width>
|
||||
<height>32</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="QPlainTextEdit" name="fParam_plainTextEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>90</y>
|
||||
<width>631</width>
|
||||
<height>331</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string>###############################################################
|
||||
FITPARAMETER
|
||||
# Nr. Name Value Step Pos_Error Boundaries</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fAdd_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>560</x>
|
||||
<y>50</y>
|
||||
<width>75</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Add</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fParamNo_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>31</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>No.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fName_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>60</x>
|
||||
<y>30</y>
|
||||
<width>46</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fValue_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>30</y>
|
||||
<width>46</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Value</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fStep_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>270</x>
|
||||
<y>30</y>
|
||||
<width>46</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Step</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fBoundaries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>370</x>
|
||||
<y>10</y>
|
||||
<width>171</width>
|
||||
<height>71</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Boundaries</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fLower_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>20</y>
|
||||
<width>46</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Lower</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fUpper_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>90</x>
|
||||
<y>20</y>
|
||||
<width>46</width>
|
||||
<height>13</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Upper</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fLower_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>40</y>
|
||||
<width>71</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>none</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fUpper_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>90</x>
|
||||
<y>40</y>
|
||||
<width>71</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>none</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QSpinBox" name="fParamNo_spinBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>50</y>
|
||||
<width>42</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>999</number>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fName_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>60</x>
|
||||
<y>50</y>
|
||||
<width>113</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fValue_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>50</y>
|
||||
<width>81</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fStep_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>270</x>
|
||||
<y>50</y>
|
||||
<width>81</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fParamNo_spinBox</tabstop>
|
||||
<tabstop>fName_lineEdit</tabstop>
|
||||
<tabstop>fValue_lineEdit</tabstop>
|
||||
<tabstop>fStep_lineEdit</tabstop>
|
||||
<tabstop>fLower_lineEdit</tabstop>
|
||||
<tabstop>fUpper_lineEdit</tabstop>
|
||||
<tabstop>fAdd_pushButton</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fParam_plainTextEdit</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetParameterBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>639</x>
|
||||
<y>434</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>338</x>
|
||||
<y>429</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetParameterBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>548</x>
|
||||
<y>436</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>448</x>
|
||||
<y>438</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fAdd_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetParameterBlockDialog</receiver>
|
||||
<slot>paramAdd()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>594</x>
|
||||
<y>59</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>562</x>
|
||||
<y>16</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetParameterBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>62</x>
|
||||
<y>447</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>148</x>
|
||||
<y>443</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>paramAdd()</slot>
|
||||
</slots>
|
||||
</ui>
|
269
src/musredit_qt5/forms/PGetPlotBlockDialog.ui
Normal file
@ -0,0 +1,269 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetPlotBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetPlotBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>719</width>
|
||||
<height>312</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Plot</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset>
|
||||
<normaloff>:/musredit/musrfit.xpm</normaloff>:/musredit/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>702</width>
|
||||
<height>292</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout_2">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="fType_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>9</pointsize>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Type</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QComboBox" name="fType_comboBox">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Single Histo</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Asymmetry</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MuMinus</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>NonMusr</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="fRunList_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>9</pointsize>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Run List</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QLineEdit" name="fRunList_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QGridLayout" name="gridLayout">
|
||||
<item row="0" column="0">
|
||||
<widget class="QLabel" name="fXRange_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>9</pointsize>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Time-/x-Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="0" column="1">
|
||||
<widget class="QLineEdit" name="fXRangeLow_lineEdit"/>
|
||||
</item>
|
||||
<item row="0" column="2">
|
||||
<widget class="QLineEdit" name="fXRangeUp_lineEdit"/>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QLabel" name="fYRange_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>9</pointsize>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>y-Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="1">
|
||||
<widget class="QLineEdit" name="fYRangeLow_lineEdit"/>
|
||||
</item>
|
||||
<item row="1" column="2">
|
||||
<widget class="QLineEdit" name="fYRangeUp_lineEdit"/>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fAdd_pushButton">
|
||||
<property name="text">
|
||||
<string>&Add</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPlainTextEdit" name="fPlot_plainTextEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>118</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetPlotBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>579</x>
|
||||
<y>311</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>355</x>
|
||||
<y>225</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetPlotBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>488</x>
|
||||
<y>311</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>243</x>
|
||||
<y>227</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetPlotBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>51</x>
|
||||
<y>311</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>115</x>
|
||||
<y>221</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fAdd_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetPlotBlockDialog</receiver>
|
||||
<slot>addPlot()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>536</x>
|
||||
<y>36</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>291</x>
|
||||
<y>316</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>addPlot()</slot>
|
||||
</slots>
|
||||
</ui>
|
654
src/musredit_qt5/forms/PGetSingleHistoRunBlockDialog.ui
Normal file
@ -0,0 +1,654 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetSingleHistoRunBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetSingleHistoRunBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>440</width>
|
||||
<height>592</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Single Histogram Run Block Parameters</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fRunHeaderInfo_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>0</y>
|
||||
<width>421</width>
|
||||
<height>121</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Run Header Info</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fRunFileName_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>91</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Run File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBeamline_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>71</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Beamline</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fInstitute_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>90</y>
|
||||
<width>56</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Institute</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFileFormat_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>240</x>
|
||||
<y>90</y>
|
||||
<width>91</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>File Format</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fRunFileName_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>26</y>
|
||||
<width>291</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBeamline_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>56</y>
|
||||
<width>113</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fInstitute_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>120</x>
|
||||
<y>86</y>
|
||||
<width>77</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>RAL</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>TRIUMF</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>JPARC</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fFileFormat_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>316</x>
|
||||
<y>86</y>
|
||||
<width>91</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>NeXuS</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-NPP</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ROOT-PPC</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI-BIN</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>PSI-MDU</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MUD</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>MDU-ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>ASCII</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>DB</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fRequiredEntries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>120</y>
|
||||
<width>421</width>
|
||||
<height>301</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Required Entries</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fMap_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>56</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Map</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fForwardHistoNo_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>111</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Forward Histo No</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fDataRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>120</y>
|
||||
<width>81</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Data Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackgroundFix_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>150</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Fix</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fOr_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>240</x>
|
||||
<y>150</y>
|
||||
<width>31</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>75</weight>
|
||||
<bold>true</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OR</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackgroundRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>210</y>
|
||||
<width>121</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fFitRange_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>240</y>
|
||||
<width>71</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Fit Range</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fMap_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>60</x>
|
||||
<y>26</y>
|
||||
<width>351</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>0 0 0 0 0 0 0 0 0</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fForwardHistoNo_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>116</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fDataEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>116</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundFix_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>146</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>206</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>206</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fFitRangeStart_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>236</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fFitRangeEnd_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>220</x>
|
||||
<y>236</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fPacking_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>266</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>1</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fPacking_textLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>270</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Packing/Binning</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fNorm_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>90</y>
|
||||
<width>56</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Norm</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fNorm_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>86</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fBackgroundFit_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>180</y>
|
||||
<width>101</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Background Fit</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fBackgroundFit_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>150</x>
|
||||
<y>176</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fOptionalEntries_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>420</y>
|
||||
<width>421</width>
|
||||
<height>121</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Optional Entries</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fT0_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>30</y>
|
||||
<width>241</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>t0 (reqired if not given in the data file)</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fT0_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>260</x>
|
||||
<y>26</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLabel" name="fMuonLifetimeParameter_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>20</x>
|
||||
<y>60</y>
|
||||
<width>211</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Muon Lifetime Parameter</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fLifetime_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>56</y>
|
||||
<width>71</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fLifetimeCorrection_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>18</x>
|
||||
<y>90</y>
|
||||
<width>151</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Lifetime Correction</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>545</y>
|
||||
<width>421</width>
|
||||
<height>39</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>188</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetSingleHistoRunBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>458</x>
|
||||
<y>434</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>471</x>
|
||||
<y>415</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetSingleHistoRunBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>394</x>
|
||||
<y>438</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>407</x>
|
||||
<y>406</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetSingleHistoRunBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>47</x>
|
||||
<y>437</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>70</x>
|
||||
<y>398</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
264
src/musredit_qt5/forms/PGetTheoryBlockDialog.ui
Normal file
@ -0,0 +1,264 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetTheoryBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetTheoryBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>698</width>
|
||||
<height>546</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Theory</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QTextEdit" name="fDescription_textEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>681</width>
|
||||
<height>211</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="readOnly">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="html">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:9pt; font-weight:400; font-style:normal;">
|
||||
<table border="0" style="-qt-table-type: root; margin-top:4px; margin-bottom:4px; margin-left:4px; margin-right:4px;">
|
||||
<tr>
|
||||
<td style="border: none;">
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Every theory function has to be written on a single line. It starts with the theory function name or its abbreviation followed by the parameters. Consecutive lines of theory functions will be multiplied. If theory functions need to be added, a line with a '+' has to separate them. The parameters are given as the numbers assigned to them in the FITPARAMETER-block.</p>
|
||||
<p style="-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;"></p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Example:</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">asymmetry 2</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">simplExpo 3</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">TFieldCos map1 fun2</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">+</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">asymmetry 6</p>
|
||||
<p style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">simplExpo 7</p></td></tr></table></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fTheoryInput_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>220</y>
|
||||
<width>681</width>
|
||||
<height>71</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Theory Input Line</string>
|
||||
</property>
|
||||
<widget class="QComboBox" name="fTheoryFunction_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>20</y>
|
||||
<width>541</width>
|
||||
<height>41</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fPlus_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>560</x>
|
||||
<y>30</y>
|
||||
<width>51</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>+</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fMultiply_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>620</x>
|
||||
<y>30</y>
|
||||
<width>51</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>*</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QPlainTextEdit" name="fTheoryBlock_plainTextEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>300</y>
|
||||
<width>681</width>
|
||||
<height>201</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="plainText">
|
||||
<string>#####################################################
|
||||
THEORY</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>510</y>
|
||||
<width>681</width>
|
||||
<height>29</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>178</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fTheoryFunction_comboBox</tabstop>
|
||||
<tabstop>fPlus_pushButton</tabstop>
|
||||
<tabstop>fMultiply_pushButton</tabstop>
|
||||
<tabstop>fTheoryBlock_plainTextEdit</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
<tabstop>fDescription_textEdit</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTheoryBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>539</x>
|
||||
<y>502</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>492</x>
|
||||
<y>411</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTheoryBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>458</x>
|
||||
<y>502</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>380</x>
|
||||
<y>472</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTheoryBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>45</x>
|
||||
<y>502</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>90</x>
|
||||
<y>440</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fPlus_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTheoryBlockDialog</receiver>
|
||||
<slot>addPlus()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>434</x>
|
||||
<y>257</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>173</x>
|
||||
<y>500</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fMultiply_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTheoryBlockDialog</receiver>
|
||||
<slot>addMultiply()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>500</x>
|
||||
<y>263</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>256</x>
|
||||
<y>504</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>addPlus()</slot>
|
||||
<slot>addMultiply()</slot>
|
||||
</slots>
|
||||
</ui>
|
166
src/musredit_qt5/forms/PGetTitleBlockDialog.ui
Normal file
@ -0,0 +1,166 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PGetTitleBlockDialog</class>
|
||||
<widget class="QDialog" name="PGetTitleBlockDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>556</width>
|
||||
<height>90</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Get Title</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QLabel" name="fTitle_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>31</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Title</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QLineEdit" name="fTitle_lineEdit">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>50</x>
|
||||
<y>6</y>
|
||||
<width>501</width>
|
||||
<height>26</height>
|
||||
</rect>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>40</y>
|
||||
<width>541</width>
|
||||
<height>47</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>138</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fTitle_lineEdit</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTitleBlockDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>467</x>
|
||||
<y>78</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>286</x>
|
||||
<y>221</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTitleBlockDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>548</x>
|
||||
<y>78</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>350</x>
|
||||
<y>219</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PGetTitleBlockDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>59</x>
|
||||
<y>64</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>149</x>
|
||||
<y>49</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
</slots>
|
||||
</ui>
|
739
src/musredit_qt5/forms/PMsr2DataDialog.ui
Normal file
@ -0,0 +1,739 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PMsr2DataDialog</class>
|
||||
<widget class="QDialog" name="PMsr2DataDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>552</width>
|
||||
<height>551</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>msr2data input</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrmsr2data.xpm</normaloff>:/images/musrmsr2data.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fRunListInput_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>551</width>
|
||||
<height>131</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="font">
|
||||
<font>
|
||||
<weight>50</weight>
|
||||
<bold>false</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Run List Input</string>
|
||||
</property>
|
||||
<property name="flat">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="checkable">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>531</width>
|
||||
<height>97</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLabel" name="fFirst_label">
|
||||
<property name="text">
|
||||
<string>First</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fFirst_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Expanding</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fLast_label">
|
||||
<property name="text">
|
||||
<string>Last</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fLast_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_3">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Fixed</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>200</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fOrFirstLast_label">
|
||||
<property name="text">
|
||||
<string><b>OR</b></string>
|
||||
</property>
|
||||
<property name="textFormat">
|
||||
<enum>Qt::AutoText</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_3">
|
||||
<item>
|
||||
<widget class="QLabel" name="fRunList_label">
|
||||
<property name="text">
|
||||
<string>Run List</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fRunList_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_4">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Minimum</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>28</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fOrRunList_label">
|
||||
<property name="text">
|
||||
<string><b>OR</b></string>
|
||||
</property>
|
||||
<property name="textFormat">
|
||||
<enum>Qt::AutoText</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<widget class="QLabel" name="fRunListFileName_label">
|
||||
<property name="text">
|
||||
<string>Run List File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fRunListFileName_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<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>52</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fMsrFileExtension_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>130</y>
|
||||
<width>551</width>
|
||||
<height>71</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>msr File Extension</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>531</width>
|
||||
<height>29</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||
<item>
|
||||
<widget class="QLabel" name="fExtension_label">
|
||||
<property name="text">
|
||||
<string>Extension</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_6">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fMsrFileExtension_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_7">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fTemplateRunInput_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>200</y>
|
||||
<width>551</width>
|
||||
<height>80</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Template Run Input</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>531</width>
|
||||
<height>29</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
||||
<item>
|
||||
<widget class="QLabel" name="fTemplateRunNumber_label">
|
||||
<property name="text">
|
||||
<string>Template Run Number</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fTemplateRunNumber_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fChainFit_checkBox">
|
||||
<property name="text">
|
||||
<string>Chain Fit</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_8">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fDataOutputFileName_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>280</y>
|
||||
<width>551</width>
|
||||
<height>80</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Data Output File Name</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>531</width>
|
||||
<height>29</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_7">
|
||||
<item>
|
||||
<widget class="QLabel" name="fDataOutputFileName_label">
|
||||
<property name="text">
|
||||
<string>Data Output File Name</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fDataOutputFileName_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_9">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::Preferred</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fOptions_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>360</y>
|
||||
<width>551</width>
|
||||
<height>141</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Options</string>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>6</x>
|
||||
<y>20</y>
|
||||
<width>541</width>
|
||||
<height>116</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_9">
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fWriteDataHeader_checkBox">
|
||||
<property name="text">
|
||||
<string>Write Data Header</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fIgnoreDataHeaderInfo_checkBox">
|
||||
<property name="text">
|
||||
<string>Ignore Data Header Info</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fKeepMinuit2Output_checkBox">
|
||||
<property name="text">
|
||||
<string>Keep Minuit2 Output</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fWriteColumnData_checkBox">
|
||||
<property name="text">
|
||||
<string>Write Column Data</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fRecreateDataFile_checkBox">
|
||||
<property name="text">
|
||||
<string>Recreate Data File</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fOpenFilesAfterFitting_checkBox">
|
||||
<property name="text">
|
||||
<string>Open Files after Fitting</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_5">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fTitleFromData_checkBox">
|
||||
<property name="text">
|
||||
<string>Take Data File Title</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fCreateMsrFileOnly_checkBox">
|
||||
<property name="text">
|
||||
<string>Create msr-File only</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fFitOnly_checkBox">
|
||||
<property name="text">
|
||||
<string>Fit Only</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_8">
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fGlobal_checkBox">
|
||||
<property name="text">
|
||||
<string>Global</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QCheckBox" name="fGlobalPlus_checkBox">
|
||||
<property name="text">
|
||||
<string>Global+</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>5</x>
|
||||
<y>500</y>
|
||||
<width>541</width>
|
||||
<height>51</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="Line" name="line">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>178</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fFirst_lineEdit</tabstop>
|
||||
<tabstop>fLast_lineEdit</tabstop>
|
||||
<tabstop>fRunList_lineEdit</tabstop>
|
||||
<tabstop>fRunListFileName_lineEdit</tabstop>
|
||||
<tabstop>fMsrFileExtension_lineEdit</tabstop>
|
||||
<tabstop>fTemplateRunNumber_lineEdit</tabstop>
|
||||
<tabstop>fChainFit_checkBox</tabstop>
|
||||
<tabstop>fDataOutputFileName_lineEdit</tabstop>
|
||||
<tabstop>fWriteDataHeader_checkBox</tabstop>
|
||||
<tabstop>fIgnoreDataHeaderInfo_checkBox</tabstop>
|
||||
<tabstop>fKeepMinuit2Output_checkBox</tabstop>
|
||||
<tabstop>fWriteColumnData_checkBox</tabstop>
|
||||
<tabstop>fRecreateDataFile_checkBox</tabstop>
|
||||
<tabstop>fOpenFilesAfterFitting_checkBox</tabstop>
|
||||
<tabstop>fTitleFromData_checkBox</tabstop>
|
||||
<tabstop>fCreateMsrFileOnly_checkBox</tabstop>
|
||||
<tabstop>fFitOnly_checkBox</tabstop>
|
||||
<tabstop>fGlobal_checkBox</tabstop>
|
||||
<tabstop>fGlobalPlus_checkBox</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>538</x>
|
||||
<y>534</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>508</x>
|
||||
<y>358</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>456</x>
|
||||
<y>541</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>380</x>
|
||||
<y>364</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fHelp_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>helpContent()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>59</x>
|
||||
<y>534</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>96</x>
|
||||
<y>370</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFirst_lineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>runFirstEntered(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>82</x>
|
||||
<y>44</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>113</x>
|
||||
<y>504</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fLast_lineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>runLastEntered(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>229</x>
|
||||
<y>44</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>348</x>
|
||||
<y>500</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fRunList_lineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>runListEntered(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>151</x>
|
||||
<y>77</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>183</x>
|
||||
<y>515</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fRunListFileName_lineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>runListFileNameEntered(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>295</x>
|
||||
<y>115</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>332</x>
|
||||
<y>492</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fTemplateRunNumber_lineEdit</sender>
|
||||
<signal>textChanged(QString)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>templateRunEntered(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>190</x>
|
||||
<y>245</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>137</x>
|
||||
<y>516</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFitOnly_checkBox</sender>
|
||||
<signal>stateChanged(int)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>fitOnlyChanged(int)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>544</x>
|
||||
<y>445</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>301</x>
|
||||
<y>484</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fCreateMsrFileOnly_checkBox</sender>
|
||||
<signal>stateChanged(int)</signal>
|
||||
<receiver>PMsr2DataDialog</receiver>
|
||||
<slot>createMsrFileOnlyChanged(int)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>544</x>
|
||||
<y>423</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>150</x>
|
||||
<y>487</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>helpContent()</slot>
|
||||
<slot>fitOnlyChanged(int)</slot>
|
||||
<slot>createMsrFileOnlyChanged(int)</slot>
|
||||
<slot>runFirstEntered(QString)</slot>
|
||||
<slot>runLastEntered(QString)</slot>
|
||||
<slot>runListEntered(QString)</slot>
|
||||
<slot>runListFileNameEntered(QString)</slot>
|
||||
<slot>templateRunEntered(QString)</slot>
|
||||
<slot>globalChanged(int)</slot>
|
||||
</slots>
|
||||
</ui>
|
94
src/musredit_qt5/forms/PMusrEditAbout.ui
Normal file
@ -0,0 +1,94 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PMusrEditAbout</class>
|
||||
<widget class="QDialog" name="PMusrEditAbout">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>395</width>
|
||||
<height>187</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Musr Edit About</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>11</x>
|
||||
<y>11</y>
|
||||
<width>371</width>
|
||||
<height>169</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="fMusrEditAbout_label">
|
||||
<property name="font">
|
||||
<font>
|
||||
<pointsize>24</pointsize>
|
||||
<weight>50</weight>
|
||||
<italic>true</italic>
|
||||
<bold>false</bold>
|
||||
</font>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:24pt; font-weight:400; font-style:italic;">
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">musredit ...</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fDetails_label">
|
||||
<property name="text">
|
||||
<string><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN" "http://www.w3.org/TR/REC-html40/strict.dtd">
|
||||
<html><head><meta name="qrichtext" content="1" /><style type="text/css">
|
||||
p, li { white-space: pre-wrap; }
|
||||
</style></head><body style=" font-family:'Sans Serif'; font-size:10pt; font-weight:400; font-style:normal;">
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">by Andreas Suter</p>
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">andreas.suter@psi.ch</p>
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Paul Scherrer Institute</p>
|
||||
<p align="center" style=" margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Switzerland</p></body></html></string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PMusrEditAbout</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>178</x>
|
||||
<y>271</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>226</x>
|
||||
<y>228</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
287
src/musredit_qt5/forms/PPrefsDialog.ui
Normal file
@ -0,0 +1,287 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PPrefsDialog</class>
|
||||
<widget class="QDialog" name="PPrefsDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>455</width>
|
||||
<height>168</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Preferences</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>5</y>
|
||||
<width>451</width>
|
||||
<height>161</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<widget class="QTabWidget" name="fTabWidget">
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="fGeneral_tab">
|
||||
<attribute name="title">
|
||||
<string>general</string>
|
||||
</attribute>
|
||||
<widget class="QWidget" name="layoutWidget">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>421</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QLineEdit" name="fTimeout_lineEdit"/>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="fTimeout_label">
|
||||
<property name="text">
|
||||
<string>timeout</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>208</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="fMusrfit_tab">
|
||||
<attribute name="title">
|
||||
<string>musrfit</string>
|
||||
</attribute>
|
||||
<widget class="QCheckBox" name="fKeepMn2Output_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>161</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>keep minuit2 output</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fDumpAscii_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>35</y>
|
||||
<width>151</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>dump ascii</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fDumpRoot_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>60</y>
|
||||
<width>131</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>dump root</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fTitleFromData_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>170</x>
|
||||
<y>10</y>
|
||||
<width>171</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>take title from data file</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fPerRunBlockChisq_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>170</x>
|
||||
<y>35</y>
|
||||
<width>191</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>keep per run block chisq</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fEstimateN0_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>170</x>
|
||||
<y>60</y>
|
||||
<width>161</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>estimate N0</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="fMusrview_tab">
|
||||
<attribute name="title">
|
||||
<string>musrview</string>
|
||||
</attribute>
|
||||
<widget class="QCheckBox" name="fFourier_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>141</width>
|
||||
<height>22</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>start with Fourier</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QWidget" name="fMusrt0_tab">
|
||||
<attribute name="title">
|
||||
<string>musrt0</string>
|
||||
</attribute>
|
||||
<widget class="QCheckBox" name="fEnableMusrT0_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>131</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>enable it</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QPushButton" name="fHelp_pushButton">
|
||||
<property name="text">
|
||||
<string>&Help</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>88</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fOk_pushButton">
|
||||
<property name="text">
|
||||
<string>&OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="fCancel_pushButton">
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fTabWidget</tabstop>
|
||||
<tabstop>fKeepMn2Output_checkBox</tabstop>
|
||||
<tabstop>fDumpAscii_checkBox</tabstop>
|
||||
<tabstop>fDumpRoot_checkBox</tabstop>
|
||||
<tabstop>fTitleFromData_checkBox</tabstop>
|
||||
<tabstop>fOk_pushButton</tabstop>
|
||||
<tabstop>fCancel_pushButton</tabstop>
|
||||
<tabstop>fHelp_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fCancel_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PPrefsDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>391</x>
|
||||
<y>198</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>422</x>
|
||||
<y>142</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fOk_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PPrefsDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>331</x>
|
||||
<y>199</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>293</x>
|
||||
<y>144</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
136
src/musredit_qt5/forms/PReplaceConfirmationDialog.ui
Normal file
@ -0,0 +1,136 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PReplaceConfirmationDialog</class>
|
||||
<widget class="QDialog" name="PReplaceConfirmationDialog">
|
||||
<property name="windowModality">
|
||||
<enum>Qt::WindowModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>513</width>
|
||||
<height>65</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Replace Confirmation - musredit</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QLabel" name="fTextLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>10</y>
|
||||
<width>461</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Found an occurrence of your search term.What do you want to do?</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="Line" name="line">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>7</x>
|
||||
<y>20</y>
|
||||
<width>521</width>
|
||||
<height>20</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fReplace_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>7</x>
|
||||
<y>35</y>
|
||||
<width>81</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Replace</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fReplaceAndClose_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>87</x>
|
||||
<y>35</y>
|
||||
<width>131</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Re&place and Close</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fReplaceAll_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>217</x>
|
||||
<y>35</y>
|
||||
<width>97</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Replace &All</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fFindNext_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>317</x>
|
||||
<y>35</y>
|
||||
<width>91</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Find Next</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fClose_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>407</x>
|
||||
<y>35</y>
|
||||
<width>97</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Close</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fClose_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PReplaceConfirmationDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>457</x>
|
||||
<y>58</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>468</x>
|
||||
<y>71</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|
300
src/musredit_qt5/forms/PReplaceDialog.ui
Normal file
@ -0,0 +1,300 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>PReplaceDialog</class>
|
||||
<widget class="QDialog" name="PReplaceDialog">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>345</width>
|
||||
<height>315</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Replace Text - musredit</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../musredit.qrc">
|
||||
<normaloff>:/images/musrfit.xpm</normaloff>:/images/musrfit.xpm</iconset>
|
||||
</property>
|
||||
<widget class="QGroupBox" name="fFind_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>341</width>
|
||||
<height>81</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Find</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fFind_label">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>20</y>
|
||||
<width>91</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Text to find:</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fFind_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>40</y>
|
||||
<width>321</width>
|
||||
<height>31</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fReplace_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>190</x>
|
||||
<y>290</y>
|
||||
<width>71</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Replace</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QPushButton" name="fClose_pushButton">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>270</x>
|
||||
<y>290</y>
|
||||
<width>71</width>
|
||||
<height>25</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Close</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fOptions_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>160</y>
|
||||
<width>341</width>
|
||||
<height>121</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Options</string>
|
||||
</property>
|
||||
<property name="alignment">
|
||||
<set>Qt::AlignBottom|Qt::AlignLeading|Qt::AlignLeft</set>
|
||||
</property>
|
||||
<widget class="QCheckBox" name="fCaseSensitive_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>30</y>
|
||||
<width>141</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>C&ase Sensitive</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fWholeWordsOnly_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>60</y>
|
||||
<width>141</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Whole words only</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fFromCursor_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>90</y>
|
||||
<width>141</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>From c&ursor</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fFindBackwards_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>30</y>
|
||||
<width>141</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Find &backwards</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fSelectedText_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>60</y>
|
||||
<width>141</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Selected text</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QCheckBox" name="fPromptOnReplace_checkBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>180</x>
|
||||
<y>90</y>
|
||||
<width>151</width>
|
||||
<height>23</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Prompt on replace</string>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
<widget class="Line" name="line">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>280</y>
|
||||
<width>351</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QGroupBox" name="fReplacement_groupBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>80</y>
|
||||
<width>341</width>
|
||||
<height>81</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Replace With</string>
|
||||
</property>
|
||||
<widget class="QLabel" name="fReplace_textLabel">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>20</y>
|
||||
<width>111</width>
|
||||
<height>16</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Replacement text:</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="QComboBox" name="fReplacementText_comboBox">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>10</x>
|
||||
<y>40</y>
|
||||
<width>321</width>
|
||||
<height>31</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="editable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
</widget>
|
||||
</widget>
|
||||
<tabstops>
|
||||
<tabstop>fFind_comboBox</tabstop>
|
||||
<tabstop>fReplacementText_comboBox</tabstop>
|
||||
<tabstop>fCaseSensitive_checkBox</tabstop>
|
||||
<tabstop>fWholeWordsOnly_checkBox</tabstop>
|
||||
<tabstop>fFromCursor_checkBox</tabstop>
|
||||
<tabstop>fFindBackwards_checkBox</tabstop>
|
||||
<tabstop>fSelectedText_checkBox</tabstop>
|
||||
<tabstop>fPromptOnReplace_checkBox</tabstop>
|
||||
<tabstop>fReplace_pushButton</tabstop>
|
||||
<tabstop>fClose_pushButton</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="../musredit.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>fClose_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PReplaceDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>287</x>
|
||||
<y>205</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>344</x>
|
||||
<y>228</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fReplace_pushButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>PReplaceDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>208</x>
|
||||
<y>211</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>171</x>
|
||||
<y>211</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>fFind_comboBox</sender>
|
||||
<signal>editTextChanged(QString)</signal>
|
||||
<receiver>PReplaceDialog</receiver>
|
||||
<slot>onFindTextAvailable(QString)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>183</x>
|
||||
<y>63</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>90</x>
|
||||
<y>298</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>onFindTextAvailable(QString)</slot>
|
||||
</slots>
|
||||
</ui>
|
BIN
src/musredit_qt5/images/MuonSpin-Avatar.gif
Normal file
After Width: | Height: | Size: 16 KiB |
2432
src/musredit_qt5/images/MuonSpin-Avatar.nb
Normal file
36
src/musredit_qt5/images/editcopy.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c #8b8bfd",
|
||||
"X c #3c3cfd",
|
||||
"o c #000082",
|
||||
"O c Gray0",
|
||||
"+ c None",
|
||||
"@ c Gray0",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"++++++++++++++++++++++",
|
||||
"++++++++++++++++++++++",
|
||||
"OOOOOOOO++++++++++++++",
|
||||
"O OO+++++++++++++",
|
||||
"O OOOO O O++++++++++++",
|
||||
"O O O+++++++++++",
|
||||
"O OOOO Ooooooooo++++++",
|
||||
"O Oo oo+++++",
|
||||
"O OOOOO o OOOO oXo++++",
|
||||
"O o o.Xo+++",
|
||||
"O OOOOO o OOOO o .Xo++",
|
||||
"O o oooooo+",
|
||||
"O OOOOO o OOOO o+",
|
||||
"O o o+",
|
||||
"O OOOOO o OOOOOOOOO o+",
|
||||
"O o o+",
|
||||
"OOOOOOOOo OOOOOOOOO o+",
|
||||
"++++++++o o+",
|
||||
"++++++++o OOOOOOOOO o+",
|
||||
"++++++++o o+",
|
||||
"++++++++ooooooooooooo+",
|
||||
"++++++++++++++++++++++"
|
||||
};
|
32
src/musredit_qt5/images/editcut.xpm
Normal file
@ -0,0 +1,32 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 4 1",
|
||||
" c Gray100",
|
||||
". c #000082",
|
||||
"X c Gray0",
|
||||
"o c None",
|
||||
/* pixels */
|
||||
"oooooooooooooooooooooo",
|
||||
"oooooooXoooooXoooooooo",
|
||||
"oooooooXoooooXoooooooo",
|
||||
"oooooooXoooooXoooooooo",
|
||||
"oooooooXooooXXoooooooo",
|
||||
"oooooooXXoooXooooooooo",
|
||||
"ooooooooXoooXooooooooo",
|
||||
"ooooooooXXoXXooooooooo",
|
||||
"oooooooooXXXoooooooooo",
|
||||
"oooooooooXXXoooooooooo",
|
||||
"ooooooooooXooooooooooo",
|
||||
"ooooooooo.X.oooooooooo",
|
||||
"oooooooo..o...oooooooo",
|
||||
"ooooooo.o.o.oo.ooooooo",
|
||||
"oooooo.oo.o.ooo.oooooo",
|
||||
"ooooo.ooo.o.oooo.ooooo",
|
||||
"oooo.oooo.o.oooo.ooooo",
|
||||
"oooo.oooo.oo.ooo.ooooo",
|
||||
"oooo.oooo.oo.oo.oooooo",
|
||||
"oooo.ooo.oooo..ooooooo",
|
||||
"ooooo...oooooooooooooo",
|
||||
"oooooooooooooooooooooo"
|
||||
};
|
202
src/musredit_qt5/images/editfind.xpm
Normal file
@ -0,0 +1,202 @@
|
||||
/* XPM */
|
||||
static char * editfind_xpm[] = {
|
||||
"22 22 177 2",
|
||||
" c None",
|
||||
". c #59595A",
|
||||
"+ c #3B3B3C",
|
||||
"@ c #3E3E3F",
|
||||
"# c #3C3C3D",
|
||||
"$ c #404041",
|
||||
"% c #585859",
|
||||
"& c #979797",
|
||||
"* c #5B5B5B",
|
||||
"= c #FFFFFF",
|
||||
"- c #5D5D5E",
|
||||
"; c #49494A",
|
||||
"> c #868787",
|
||||
", c #AFB4B4",
|
||||
"' c #BBC4C6",
|
||||
") c #BBC5C6",
|
||||
"! c #B2B7B7",
|
||||
"~ c #7A7A7B",
|
||||
"{ c #1D1D1D",
|
||||
"] c #474747",
|
||||
"^ c #3D3D3D",
|
||||
"/ c #444445",
|
||||
"( c #7B7879",
|
||||
"_ c #CFDADA",
|
||||
": c #E5F0F2",
|
||||
"< c #DCF2F5",
|
||||
"[ c #DDF4FA",
|
||||
"} c #D7F3F8",
|
||||
"| c #CCEFF7",
|
||||
"1 c #DCE7E9",
|
||||
"2 c #6F6F70",
|
||||
"3 c #434343",
|
||||
"4 c #E4E4E4",
|
||||
"5 c #4C4C4D",
|
||||
"6 c #7D7E7D",
|
||||
"7 c #E9F8FA",
|
||||
"8 c #C6EDF5",
|
||||
"9 c #BDE7F0",
|
||||
"0 c #A5DCEA",
|
||||
"a c #9BD6E2",
|
||||
"b c #BBE7EE",
|
||||
"c c #444444",
|
||||
"d c #8A8A8A",
|
||||
"e c #767676",
|
||||
"f c #C5CFD2",
|
||||
"g c #B1E2EC",
|
||||
"h c #9DD9E6",
|
||||
"i c #8ACDD9",
|
||||
"j c #81C9D6",
|
||||
"k c #AFE1EC",
|
||||
"l c #CED9D9",
|
||||
"m c #29292A",
|
||||
"n c #818181",
|
||||
"o c #6C6C6C",
|
||||
"p c #4A4A4A",
|
||||
"q c #5C5C5C",
|
||||
"r c #A2A7A7",
|
||||
"s c #E5F4F8",
|
||||
"t c #C3E9F0",
|
||||
"u c #ACE0EB",
|
||||
"v c #99D8E6",
|
||||
"w c #87CDDC",
|
||||
"x c #6CBACB",
|
||||
"y c #7BC4D4",
|
||||
"z c #9DA2A1",
|
||||
"A c #626262",
|
||||
"B c #727272",
|
||||
"C c #535353",
|
||||
"D c #494949",
|
||||
"E c #BAC0C1",
|
||||
"F c #E7F3F6",
|
||||
"G c #CBE9F2",
|
||||
"H c #86D1E1",
|
||||
"I c #6CC3D9",
|
||||
"J c #50A6B9",
|
||||
"K c #6AB5C3",
|
||||
"L c #B2C7CB",
|
||||
"M c #454545",
|
||||
"N c #4F4F4F",
|
||||
"O c #4B4B4B",
|
||||
"P c #373737",
|
||||
"Q c #E3F2F4",
|
||||
"R c #C5E7EC",
|
||||
"S c #A8E1EB",
|
||||
"T c #96D7E7",
|
||||
"U c #74C8DD",
|
||||
"V c #5BB1C4",
|
||||
"W c #4399A8",
|
||||
"X c #54ACB9",
|
||||
"Y c #0C0C0C",
|
||||
"Z c #D3D3D3",
|
||||
"` c #464646",
|
||||
" . c #434344",
|
||||
".. c #A6ABAA",
|
||||
"+. c #D8EDF1",
|
||||
"@. c #B1DBE4",
|
||||
"#. c #96D5E5",
|
||||
"$. c #4DBACE",
|
||||
"%. c #449AA9",
|
||||
"&. c #3D8996",
|
||||
"*. c #63B5C4",
|
||||
"=. c #ABDFEA",
|
||||
"-. c #232323",
|
||||
";. c #FCFCFC",
|
||||
">. c #78C3D3",
|
||||
",. c #68BDCF",
|
||||
"'. c #4CB7CB",
|
||||
"). c #4298A7",
|
||||
"!. c #398491",
|
||||
"~. c #489EAD",
|
||||
"{. c #404647",
|
||||
"]. c #484848",
|
||||
"^. c #797A79",
|
||||
"/. c #D7F0F4",
|
||||
"(. c #A4DBE9",
|
||||
"_. c #79BFCC",
|
||||
":. c #60B3C5",
|
||||
"<. c #52A7B3",
|
||||
"[. c #4496A5",
|
||||
"}. c #50A3B5",
|
||||
"|. c #8ACFE1",
|
||||
"1. c #000000",
|
||||
"2. c #8E8E8E",
|
||||
"3. c #5C5D5C",
|
||||
"4. c #BAE4EF",
|
||||
"5. c #99D4E0",
|
||||
"6. c #87CAD6",
|
||||
"7. c #BDE6F0",
|
||||
"8. c #414648",
|
||||
"9. c #AC993F",
|
||||
"0. c #6C6D6C",
|
||||
"a. c #7B7C7B",
|
||||
"b. c #79989C",
|
||||
"c. c #A9C7CE",
|
||||
"d. c #B3CAD0",
|
||||
"e. c #88A8AD",
|
||||
"f. c #6B7274",
|
||||
"g. c #DECE9D",
|
||||
"h. c #635920",
|
||||
"i. c #4D4D4E",
|
||||
"j. c #595959",
|
||||
"k. c #737374",
|
||||
"l. c #757576",
|
||||
"m. c #717172",
|
||||
"n. c #707071",
|
||||
"o. c #424849",
|
||||
"p. c #414748",
|
||||
"q. c #BDA44C",
|
||||
"r. c #717171",
|
||||
"s. c #686868",
|
||||
"t. c #928237",
|
||||
"u. c #747475",
|
||||
"v. c #767677",
|
||||
"w. c #373738",
|
||||
"x. c #939393",
|
||||
"y. c #E3E3E3",
|
||||
"z. c #363637",
|
||||
"A. c #777778",
|
||||
"B. c #E1E1E1",
|
||||
"C. c #39393A",
|
||||
"D. c #3B3B3B",
|
||||
"E. c #DCDCDC",
|
||||
"F. c #828282",
|
||||
"G. c #CECECE",
|
||||
"H. c #3A3F40",
|
||||
"I. c #727273",
|
||||
"J. c #313131",
|
||||
"K. c #575757",
|
||||
"L. c #393939",
|
||||
"M. c #EEEEEE",
|
||||
"N. c #3D3D3E",
|
||||
"O. c #9D9D9D",
|
||||
"P. c #FEFEFE",
|
||||
"Q. c #323233",
|
||||
"R. c #7F7F80",
|
||||
"S. c #0B0B0B",
|
||||
"T. c #4D4D4D",
|
||||
" . + @ # $ % & * = ",
|
||||
" - ; > , ' ) ! ~ { ] * ^ = & ",
|
||||
" / ( _ : < [ } | [ 1 2 3 4 4 * ",
|
||||
" 5 6 1 7 = 7 8 9 0 a b 1 6 c d e = ",
|
||||
" ; f 7 = = = 7 g h i j k l m n o * p = ",
|
||||
"q r 1 < s = 7 t u v w x y k z A B * C D = ",
|
||||
"; E F G G 7 t k v H I J K g L M N O M P ",
|
||||
"; ' Q R b g S T H U V W X S L Y Z ` P = ",
|
||||
" ...+.@.a v #.H U $.%.&.*.=.r -. ;.= ",
|
||||
"o 6 _ k i j >.,.'.).!.~.#._ {.] ",
|
||||
" ].^./.(._.:.<.[.&.}.|.+.z 1. ",
|
||||
" 2.3.6 +.4.5.6.>.w 7.+.6 8.1.9. ",
|
||||
" * 0.a.b.c.R R d.e.f.8.1.= g.h. ",
|
||||
" q i.j.k.l.m.n.o.p.1.q.g.= k.$ ",
|
||||
" r.i.N p D s. h.t.o.u.= v.w. ",
|
||||
" x.C y. h.z.o.A.B.~ C. ",
|
||||
" * D.E.F.M G. z.z.H.I.G.2 J. ",
|
||||
" = = K.L.M. 1.z.o.n.G.n.N.",
|
||||
"O.d e P.y. Q.z.o.n.R.$ ",
|
||||
"n o * ].4 & * = 1.z.o.S.$ ",
|
||||
"e * C D 4 * ^ = 1.1.$ ",
|
||||
"K.T.M P = = = "};
|
49
src/musredit_qt5/images/editnext.xpm
Normal file
@ -0,0 +1,49 @@
|
||||
/* XPM */
|
||||
static char * editnext_xpm[] = {
|
||||
"24 24 22 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #FFFFFF",
|
||||
"@ c #E6E6E6",
|
||||
"# c #FAFAFA",
|
||||
"$ c #AEAEAE",
|
||||
"% c #F6F6F6",
|
||||
"& c #C9C9C9",
|
||||
"* c #666666",
|
||||
"= c #ACACAC",
|
||||
"- c #F3F3F3",
|
||||
"; c #FDFDFD",
|
||||
"> c #676767",
|
||||
", c #AAAAAA",
|
||||
"' c #888888",
|
||||
") c #A5A5A5",
|
||||
"! c #F0F0F0",
|
||||
"~ c #525252",
|
||||
"{ c #5E5E5E",
|
||||
"] c #696969",
|
||||
"^ c #FCFCFC",
|
||||
"/ c #F9F9F9",
|
||||
" ",
|
||||
" ",
|
||||
" ........+ ",
|
||||
" . ........+ ",
|
||||
" .@. . #++++++++ ",
|
||||
" .@$%. .. ..........+ ",
|
||||
".&$*=%..@. -;+++++++++ ",
|
||||
" .>$*=&@,. ....+ ",
|
||||
" .>$*')>. !;+++ ",
|
||||
" .~${{>. .......+ ",
|
||||
" .@']]>. !^++++++ ",
|
||||
" .@,>>>>. ",
|
||||
" ......... ..........+ ",
|
||||
" ..........+ ",
|
||||
" /++++++++++ ",
|
||||
" ....+ ",
|
||||
" +++++ ",
|
||||
" ......+ ",
|
||||
" +++++++ ",
|
||||
" ........+ ",
|
||||
" +++++++++ ",
|
||||
" ",
|
||||
" ",
|
||||
" "};
|
36
src/musredit_qt5/images/editpaste.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c Yellow",
|
||||
"X c #c6c3c6",
|
||||
"o c #848284",
|
||||
"O c #848200",
|
||||
"+ c #000084",
|
||||
"@ c Gray0",
|
||||
"# c None",
|
||||
/* pixels */
|
||||
"######################",
|
||||
"#######@@@@@##########",
|
||||
"##@@@@@@...@@@@@@#####",
|
||||
"#@@@@@@.....@@@@@@####",
|
||||
"@@oOo@@.@@@.@@oOo@@###",
|
||||
"@oOo@XXXXXXXXX@oOo@###",
|
||||
"@OoO@XXXXXXXXX@OoO@###",
|
||||
"@oOo@@@@@@@@@@@oOo@###",
|
||||
"@OoOoOoOoOoOoOoOoO@###",
|
||||
"@oOoOoOoOoOoOoOoOo@###",
|
||||
"@OoOoOoO++++++++++@###",
|
||||
"@oOoOoOo+ + +###",
|
||||
"@OoOoOoO+ +++++ + +##",
|
||||
"@oOoOoOo+ + +#",
|
||||
"@OoOoOoO+ +++++ + +",
|
||||
"@oOoOoOo+ ++++++",
|
||||
"@OoOoOoO+ +++++ +",
|
||||
"@oOoOoOo+ +",
|
||||
"@OoOoOoO+ ++++++++++ +",
|
||||
"#@@@@@@@+ +",
|
||||
"########++++++++++++++",
|
||||
"######################"
|
||||
};
|
45
src/musredit_qt5/images/editprevious.xpm
Normal file
@ -0,0 +1,45 @@
|
||||
/* XPM */
|
||||
static char * editprevious_xpm[] = {
|
||||
"24 22 20 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #FFFFFF",
|
||||
"@ c #D6D6D6",
|
||||
"# c #F0F0F0",
|
||||
"$ c #FDFDFD",
|
||||
"% c #B1B1B1",
|
||||
"& c #969696",
|
||||
"* c #696969",
|
||||
"= c #FEFEFE",
|
||||
"- c #A8A8A8",
|
||||
"; c #888888",
|
||||
"> c #5E5E5E",
|
||||
", c #F7F7F7",
|
||||
"' c #666666",
|
||||
") c #ACACAC",
|
||||
"! c #A0A0A0",
|
||||
"~ c #AEAEAE",
|
||||
"{ c #3B3B3B",
|
||||
"] c #4C4C4C",
|
||||
" ",
|
||||
" ",
|
||||
"........+ ",
|
||||
"........+ ......... ",
|
||||
"+++++++++ .@@###@. ",
|
||||
"..........$ .%&*&@. ",
|
||||
"++++++++++= .-;>&,. ",
|
||||
"....+ .-;;'),. ",
|
||||
"+++++ .!~{~'),. ",
|
||||
".......+ .~..{~'),. ",
|
||||
"++++++++ .. .{~]. ",
|
||||
" . .{. ",
|
||||
"..........$ . ",
|
||||
"..........+ ",
|
||||
"+++++++++++ ",
|
||||
"....+ ",
|
||||
"+++++ ",
|
||||
"......+ ",
|
||||
"+++++++ ",
|
||||
"........+ ",
|
||||
"+++++++++ ",
|
||||
" "};
|
36
src/musredit_qt5/images/editredo.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c #848284",
|
||||
"X c #000084",
|
||||
"o c Gray0",
|
||||
"O c None",
|
||||
"+ c Gray0",
|
||||
"@ c Gray0",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOO.XXXXXXOOOOOOOOOOO",
|
||||
"OOOXXXXXXXXXXOOOOOOXOO",
|
||||
"OO.XXOOOOOOXXXXOOOXXOO",
|
||||
"OOXXOOOOOOOOOXXXOXXXOO",
|
||||
"OOXXOOOOOOOOOOXXXXXXOO",
|
||||
"OOXXOOOOOOOOOOOXXXXXOO",
|
||||
"OOXXOOOOOOOOOOXXXXXXOO",
|
||||
"OOXXOOOOOOOOOXXXXXXXOO",
|
||||
"OO.XXOOOOOOOXXXXXXXXOO",
|
||||
"OOOXXX.OOOOOOOOOOOOOOO",
|
||||
"OOOOXXXOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO"
|
||||
};
|
36
src/musredit_qt5/images/editundo.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c #848284",
|
||||
"X c #000084",
|
||||
"o c Gray0",
|
||||
"O c None",
|
||||
"+ c Gray0",
|
||||
"@ c Gray0",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOXXXXXX.OOOO",
|
||||
"OOXOOOOOOXXXXXXXXXXOOO",
|
||||
"OOXXOOOXXXXOOOOOOXX.OO",
|
||||
"OOXXXOXXXOOOOOOOOOXXOO",
|
||||
"OOXXXXXXOOOOOOOOOOXXOO",
|
||||
"OOXXXXXOOOOOOOOOOOXXOO",
|
||||
"OOXXXXXXOOOOOOOOOOXXOO",
|
||||
"OOXXXXXXXOOOOOOOOOXXOO",
|
||||
"OOXXXXXXXXOOOOOOOXX.OO",
|
||||
"OOOOOOOOOOOOOOO.XXXOOO",
|
||||
"OOOOOOOOOOOOOOOXXXOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO"
|
||||
};
|
36
src/musredit_qt5/images/filenew.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c Gray76",
|
||||
"X c Gray53",
|
||||
"o c Gray36",
|
||||
"O c Gray18",
|
||||
"+ c Gray0",
|
||||
"@ c None",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"@@@@@@@@@@@@@@@@@@@@@@",
|
||||
"@@@@++++++++++@@@@@@@@",
|
||||
"@@@@+ +O+@@@@@@@",
|
||||
"@@@@+ +oO+@@@@@@",
|
||||
"@@@@+ +XoO+@@@@@",
|
||||
"@@@@+ +.XoO+@@@@",
|
||||
"@@@@+ + .XoO+@@@",
|
||||
"@@@@+ +++++++@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+ +@@@",
|
||||
"@@@@+++++++++++++++@@@",
|
||||
"@@@@@@@@@@@@@@@@@@@@@@",
|
||||
"@@@@@@@@@@@@@@@@@@@@@@"
|
||||
};
|
36
src/musredit_qt5/images/fileopen.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c Yellow",
|
||||
"X c #848200",
|
||||
"o c Gray0",
|
||||
"O c None",
|
||||
"+ c Gray0",
|
||||
"@ c Gray0",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOooooOOOOoO",
|
||||
"OOOOOOOOOOOoOOOOooOooO",
|
||||
"OOOOOOOOOOOOOOOOOOoooO",
|
||||
"OOOOOOOOOOOOOOOOOooooO",
|
||||
"OooooOOOOOOOOOOOoooooO",
|
||||
"o. . ooooooooooOOOOOOO",
|
||||
"o . . . . . . oOOOOOOO",
|
||||
"o. . . . . . .oOOOOOOO",
|
||||
"o . . . . . . oOOOOOOO",
|
||||
"o. . . ooooooooooooooo",
|
||||
"o . . ooXXXXXXXXXXXXoo",
|
||||
"o. . ooXXXXXXXXXXXXooO",
|
||||
"o . ooXXXXXXXXXXXXooOO",
|
||||
"o. ooXXXXXXXXXXXXooOOO",
|
||||
"o ooXXXXXXXXXXXXooOOOO",
|
||||
"oooXXXXXXXXXXXXooOOOOO",
|
||||
"ooXXXXXXXXXXXXooOOOOOO",
|
||||
"oooooooooooooooOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOO"
|
||||
};
|
117
src/musredit_qt5/images/fileprint.xpm
Normal file
@ -0,0 +1,117 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 89 1",
|
||||
" c Gray0",
|
||||
". c #101008081010",
|
||||
"X c #101010101010",
|
||||
"o c #101010101818",
|
||||
"O c #181810101818",
|
||||
"+ c #181818181818",
|
||||
"@ c #181818182121",
|
||||
"# c #212118182121",
|
||||
"$ c Gray13",
|
||||
"% c #212121212929",
|
||||
"& c #292921212929",
|
||||
"* c Gray16",
|
||||
"= c #292929293131",
|
||||
"- c #313129293131",
|
||||
"; c #313131313131",
|
||||
": c #313131313939",
|
||||
"> c #393931313939",
|
||||
", c #393939393939",
|
||||
"< c #393939394242",
|
||||
"1 c #424239394242",
|
||||
"2 c Gray26",
|
||||
"3 c #4a4a4a4a5252",
|
||||
"4 c #5a5a52525a5a",
|
||||
"5 c #5a5a5a5a6363",
|
||||
"6 c #6b6b63636b6b",
|
||||
"7 c Gray42",
|
||||
"8 c #6b6b6b6b7373",
|
||||
"9 c #73736b6b7373",
|
||||
"0 c #7b7b73737b7b",
|
||||
"q c #7b7b73738484",
|
||||
"w c #0808ffff0808",
|
||||
"e c #2929ffff2929",
|
||||
"r c #3131ffff3131",
|
||||
"t c #5a5acece5a5a",
|
||||
"y c #6b6bffff6363",
|
||||
"u c #7b7bffff7b7b",
|
||||
"i c #84847b7b8484",
|
||||
"p c #84847b7b8c8c",
|
||||
"a c #8c8c7b7b9494",
|
||||
"s c #848484848c8c",
|
||||
"d c #8c8c84848c8c",
|
||||
"f c Gray55",
|
||||
"g c #8c8c84849494",
|
||||
"h c #8c8c8c8c9494",
|
||||
"j c #94948c8c9494",
|
||||
"k c #94948c8c9c9c",
|
||||
"l c Gray58",
|
||||
"z c #949494949c9c",
|
||||
"x c #9c9c94949c9c",
|
||||
"c c Gray61",
|
||||
"v c #9c9c9494a5a5",
|
||||
"b c #9c9c9c9ca5a5",
|
||||
"n c #a5a59c9ca5a5",
|
||||
"m c #a5a59c9cadad",
|
||||
"M c #adad9c9cadad",
|
||||
"N c #a5a5a5a5a5a5",
|
||||
"B c #a5a5a5a5adad",
|
||||
"V c #adada5a5adad",
|
||||
"C c Gray68",
|
||||
"Z c #adadadadb5b5",
|
||||
"A c #b5b5adadb5b5",
|
||||
"S c Gray71",
|
||||
"D c Gray74",
|
||||
"F c #9494c6c69494",
|
||||
"G c #9c9ccecea5a5",
|
||||
"H c #bdbdd6d6bdbd",
|
||||
"J c #c0c0c0c0c0c0",
|
||||
"K c #c6c6c6c6c6c6",
|
||||
"L c #cecec6c6cece",
|
||||
"P c #cececececece",
|
||||
"I c #cecececed6d6",
|
||||
"U c #d6d6ceced6d6",
|
||||
"Y c #d6d6cecedede",
|
||||
"T c Gray84",
|
||||
"R c #d6d6d6d6dede",
|
||||
"E c #deded6d6dede",
|
||||
"W c Gray87",
|
||||
"Q c #deded6d6e7e7",
|
||||
"! c #dedededee7e7",
|
||||
"~ c #d6d6ffffd6d6",
|
||||
"^ c #e7e7dedee7e7",
|
||||
"/ c #e7e7e7e7e7e7",
|
||||
"( c #e7e7e7e7efef",
|
||||
") c #efefe7e7efef",
|
||||
"_ c #efefefefefef",
|
||||
"` c #e7e7ffffe7e7",
|
||||
"' c Gray97",
|
||||
"] c Gray100",
|
||||
"[ c None",
|
||||
/* pixels */
|
||||
"[[[[[[SDPPPPKKDDCD[[[[",
|
||||
"[[[[[[D_/////___WD[[[[",
|
||||
"[[[[[[DKKKPPKKKKDK[[[[",
|
||||
"[[[[[[SDDDDSDDSSCD[[[[",
|
||||
"[[[[[KCKDKKKDDDKS[[[[[",
|
||||
"[[[[[DDSDDDDDDKKS[[[[[",
|
||||
"[[[[[DSKDDDDDKDKC[[[[[",
|
||||
"[[[[[KDDDDDDDDDDS[[[[[",
|
||||
"[[[[[CP/WWWWWWTWNNZ[[[",
|
||||
"[[[Dc9STPTPTPTWWj427S[",
|
||||
"[[Dziq0000000pag8<%@2N",
|
||||
"[DcE(!ERRRRUYGtFn2##O<",
|
||||
"Db)]]]]]]]]]~ewePa;@X#",
|
||||
"V']]]]]]]]]]`yru]Q0@ #",
|
||||
"BRILITRRW^!E!RHUILhO @",
|
||||
"jAZVBmBnmmNmnmMvzh6o #",
|
||||
"jZZmBnnnbnbbbbvxxg6o +",
|
||||
"lmmnbnbbbvcvxxxvjs6O 3",
|
||||
"jBnnvcvxvcvxvxzjhd8o+C",
|
||||
"lsdgfgdhgdhhjhjkhg6+l[",
|
||||
"S9%@$%&&&=--::>>:-:l[[",
|
||||
"[[C511,:;;;**%++.2c[[["
|
||||
};
|
172
src/musredit_qt5/images/filereload.xpm
Normal file
@ -0,0 +1,172 @@
|
||||
/* XPM */
|
||||
static char * editreload_xpm[] = {
|
||||
"22 22 147 2",
|
||||
" c None",
|
||||
". c #215017",
|
||||
"+ c #225118",
|
||||
"@ c #1C3F10",
|
||||
"# c #1C4110",
|
||||
"$ c #213B14",
|
||||
"% c #1A330D",
|
||||
"& c #141400",
|
||||
"* c #1D4613",
|
||||
"= c #2A732F",
|
||||
"- c #65C284",
|
||||
"; c #D8F0D6",
|
||||
"> c #B9E4BD",
|
||||
", c #82CD91",
|
||||
"' c #3D8F4B",
|
||||
") c #477D40",
|
||||
"! c #417036",
|
||||
"~ c #1E4917",
|
||||
"{ c #1B3E0F",
|
||||
"] c #32A85D",
|
||||
"^ c #FFFFFF",
|
||||
"/ c #B8E2BE",
|
||||
"( c #46B670",
|
||||
"_ c #2F833C",
|
||||
": c #112405",
|
||||
"< c #121600",
|
||||
"[ c #212106",
|
||||
"} c #142B0A",
|
||||
"| c #B2E0B8",
|
||||
"1 c #47B671",
|
||||
"2 c #50854A",
|
||||
"3 c #686868",
|
||||
"4 c #6E6E6E",
|
||||
"5 c #101800",
|
||||
"6 c #CBE9CB",
|
||||
"7 c #63C284",
|
||||
"8 c #337F3A",
|
||||
"9 c #17320C",
|
||||
"0 c #747474",
|
||||
"a c #2A6F2B",
|
||||
"b c #A3DAAE",
|
||||
"c c #31843E",
|
||||
"d c #676767",
|
||||
"e c #7B7B7B",
|
||||
"f c #296C27",
|
||||
"g c #E0F3DD",
|
||||
"h c #63C385",
|
||||
"i c #46914F",
|
||||
"j c #142908",
|
||||
"k c #6D6D6D",
|
||||
"l c #284919",
|
||||
"m c #305020",
|
||||
"n c #2FA057",
|
||||
"o c #BEE5C1",
|
||||
"p c #55BD7A",
|
||||
"q c #32843F",
|
||||
"r c #192C0B",
|
||||
"s c #161600",
|
||||
"t c #2C7F39",
|
||||
"u c #B0E1B5",
|
||||
"v c #DFF3DD",
|
||||
"w c #D4F4D4",
|
||||
"x c #6FC386",
|
||||
"y c #419652",
|
||||
"z c #378843",
|
||||
"A c #7DCB8F",
|
||||
"B c #CEECCE",
|
||||
"C c #2C813A",
|
||||
"D c #16310C",
|
||||
"E c #000000",
|
||||
"F c #171717",
|
||||
"G c #366D2F",
|
||||
"H c #32A65C",
|
||||
"I c #34B464",
|
||||
"J c #319E52",
|
||||
"K c #3A924C",
|
||||
"L c #64C280",
|
||||
"M c #256022",
|
||||
"N c #A0A0A0",
|
||||
"O c #474747",
|
||||
"P c #191919",
|
||||
"Q c #2F8F46",
|
||||
"R c #33B364",
|
||||
"S c #6AC684",
|
||||
"T c #5A5A5A",
|
||||
"U c #B8B8B8",
|
||||
"V c #848484",
|
||||
"W c #454545",
|
||||
"X c #151515",
|
||||
"Y c #407438",
|
||||
"Z c #2F8B40",
|
||||
"` c #2D823B",
|
||||
" . c #C3C3C3",
|
||||
".. c #383838",
|
||||
"+. c #484848",
|
||||
"@. c #8D8D8D",
|
||||
"#. c #4C4C4C",
|
||||
"$. c #B5B5B5",
|
||||
"%. c #6F6F6F",
|
||||
"&. c #353535",
|
||||
"*. c #222222",
|
||||
"=. c #292929",
|
||||
"-. c #4D4D4D",
|
||||
";. c #464646",
|
||||
">. c #282828",
|
||||
",. c #9B9B9B",
|
||||
"'. c #2A2A2A",
|
||||
"). c #2F2F2F",
|
||||
"!. c #2E2E2E",
|
||||
"~. c #717171",
|
||||
"{. c #2C2C2C",
|
||||
"]. c #0A0A0A",
|
||||
"^. c #030303",
|
||||
"/. c #757575",
|
||||
"(. c #3C3C3C",
|
||||
"_. c #515151",
|
||||
":. c #242424",
|
||||
"<. c #010101",
|
||||
"[. c #898989",
|
||||
"}. c #414141",
|
||||
"|. c #575757",
|
||||
"1. c #252525",
|
||||
"2. c #A3A3A3",
|
||||
"3. c #3B3B3B",
|
||||
"4. c #1A1A1A",
|
||||
"5. c #AFAFAF",
|
||||
"6. c #6A6A6A",
|
||||
"7. c #434343",
|
||||
"8. c #404040",
|
||||
"9. c #070707",
|
||||
"0. c #424242",
|
||||
"a. c #141414",
|
||||
"b. c #080808",
|
||||
"c. c #0B0B0B",
|
||||
"d. c #1C1C1C",
|
||||
"e. c #797979",
|
||||
"f. c #828282",
|
||||
"g. c #505050",
|
||||
"h. c #1F1F1F",
|
||||
"i. c #4B4B4B",
|
||||
"j. c #818181",
|
||||
"k. c #A5A5A5",
|
||||
"l. c #5E5E5E",
|
||||
"m. c #0D0D0D",
|
||||
"n. c #121212",
|
||||
"o. c #212121",
|
||||
"p. c #1D1D1D",
|
||||
" . + @ # $ % & ",
|
||||
" * = - ; > , ' ) ! ~ { ",
|
||||
" * ] ^ / ( _ * : < [ & ~ } ",
|
||||
" = ^ | 1 2 & & 3 4 & } 5 ",
|
||||
" * - 6 7 8 9 3 0 } & ",
|
||||
" a ^ b c & d e & ",
|
||||
" f g h i j k ",
|
||||
"& { l m n o p q r s & & ",
|
||||
"& t u v w x y z A B C D E F ",
|
||||
" & G H I J K L C M & E N O P ",
|
||||
" & G Q R S C M & T E U k V W X ",
|
||||
" & Y Z ` M & E .4 ..+.@.#.P ",
|
||||
" & G M & E $.%.&.*.=.-.@.;.X ",
|
||||
" & & >.,.3 W W '.).!.;.~.{.].",
|
||||
" E E ^.E /.(._.:.<.E E E ",
|
||||
" E [.}.|.1. ",
|
||||
" E E 2.3._.4. ",
|
||||
" E E E 5.6.7.8.9. ",
|
||||
" E E E E E 5.V 0.+.a. ",
|
||||
" b.*.c.d.E E e.5.f.g.g.{.9. ",
|
||||
" E h.i.6.j.k.l.0.g.m.E ",
|
||||
" ].n.P h.o.p.E "};
|
36
src/musredit_qt5/images/filesave.xpm
Normal file
@ -0,0 +1,36 @@
|
||||
/* XPM */
|
||||
static char *magick[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"22 22 8 1",
|
||||
" c Gray100",
|
||||
". c #cab5d1",
|
||||
"X c #c1c1c1",
|
||||
"o c #848200",
|
||||
"O c Gray0",
|
||||
"+ c None",
|
||||
"@ c Gray0",
|
||||
"# c Gray0",
|
||||
/* pixels */
|
||||
"++++++++++++++++++++++",
|
||||
"+OOOOOOOOOOOOOOOOOOOO+",
|
||||
"+OooOXXXXXXXXXXXXOXXO+",
|
||||
"+OooOXXXXXXXXXXXXOXXO+",
|
||||
"+OooOXXXXXXXXX.XXOOOO+",
|
||||
"+OooOXXX..XXXXXXXOooO+",
|
||||
"+OooOXXX..XXXXXXXOooO+",
|
||||
"+OooOXXXXXXXXXXXXOooO+",
|
||||
"+OooOXXXXXXXXXXXXOooO+",
|
||||
"+OooOXXXXXXXXXXXXOooO+",
|
||||
"+OooOXXXXXXXXXXXXOooO+",
|
||||
"+OoooOOOOOOOOOOOOoooO+",
|
||||
"+OooooooooooooooooooO+",
|
||||
"+OooooooooooooooooooO+",
|
||||
"+OoooOOOOOOOOOOOOOooO+",
|
||||
"+OoooOOOOOOOOOXXXOooO+",
|
||||
"+OoooOOOOOOOOOXXXOooO+",
|
||||
"+OoooOOOOOOOOOXXXOooO+",
|
||||
"+OoooOOOOOOOOOXXXOooO+",
|
||||
"+OoooOOOOOOOOOXXXOooO+",
|
||||
"++OOOOOOOOOOOOOOOOOO++",
|
||||
"++++++++++++++++++++++"
|
||||
};
|
28
src/musredit_qt5/images/musrFT.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char *dummy[]={
|
||||
"22 22 3 1",
|
||||
". c None",
|
||||
"# c #000000",
|
||||
"a c #ff0000",
|
||||
"..##....###...##......",
|
||||
"......................",
|
||||
"######################",
|
||||
"......................",
|
||||
".........a............",
|
||||
".........a............",
|
||||
".........a............",
|
||||
".........a............",
|
||||
".........aa...........",
|
||||
"........aaa...........",
|
||||
"........aaa...........",
|
||||
"........a.a...........",
|
||||
"........a.a...........",
|
||||
".......aa.aa..........",
|
||||
".......aa..aa.........",
|
||||
"a.aaa..a....aaa...aa..",
|
||||
"aa.aaa.a......aaa.aaaa",
|
||||
"......a..........aa...",
|
||||
"######################",
|
||||
"......................",
|
||||
".#######.####..####...",
|
||||
"......................"};
|
29
src/musredit_qt5/images/musrasym.xpm
Normal file
@ -0,0 +1,29 @@
|
||||
/* XPM */
|
||||
static char * musrasym_xpm[] = {
|
||||
"22 22 4 1",
|
||||
" c None",
|
||||
". c #3D20CF",
|
||||
"+ c #FF0000",
|
||||
"@ c #000000",
|
||||
" ",
|
||||
" . .. . . . .",
|
||||
" . . . . . . .. ..",
|
||||
". . . . . . . .",
|
||||
". . .. . . . .",
|
||||
"..... . . . .",
|
||||
". . . . . . .",
|
||||
". . .. . . .",
|
||||
" ",
|
||||
" ++ ",
|
||||
"+ + ",
|
||||
" + ",
|
||||
" + ",
|
||||
" + ",
|
||||
" + ++ ",
|
||||
" + + + +",
|
||||
"@@@@@@@+@@@@+@@@@+@@+ ",
|
||||
" + + ++ ",
|
||||
" ++ ",
|
||||
" ",
|
||||
" ",
|
||||
" "};
|
28
src/musredit_qt5/images/musrcalcchisq.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrcalcchisq_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #FF0000",
|
||||
"+ c #000000",
|
||||
" ... ",
|
||||
" +... . ",
|
||||
" .+ ...+. ",
|
||||
" ... . ... ",
|
||||
" ... ... ",
|
||||
" ... ... ",
|
||||
"+ . . ",
|
||||
" . ",
|
||||
" +++ ",
|
||||
" ++..+ ",
|
||||
" + ..+ . ",
|
||||
" .+.+ . ",
|
||||
"++ + +. + ... ",
|
||||
"+++ ++ + ...++... ",
|
||||
" ++ ++ +++++.. ... ",
|
||||
" +++ ... .+ ",
|
||||
" ++ . ",
|
||||
" ++ ...",
|
||||
" +++ ...",
|
||||
" ++ + ...",
|
||||
" ++ +++ . ",
|
||||
"++ +++ "};
|
28
src/musredit_qt5/images/musrdump.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrdump_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #0000FF",
|
||||
"+ c #000000",
|
||||
"... . . . . ... ",
|
||||
". . . . .. .. . .",
|
||||
". . . . . . . . .",
|
||||
". . . . . . . . .",
|
||||
". . . . . . ... ",
|
||||
". . . . . . . ",
|
||||
"... ... . . . ",
|
||||
" ",
|
||||
" ",
|
||||
"+++ ",
|
||||
" ++++ ",
|
||||
" + ",
|
||||
" ++++ ",
|
||||
" + ",
|
||||
" ++++ ",
|
||||
" + + ",
|
||||
" + +++++ ",
|
||||
" + +++ ",
|
||||
" ++++ + ",
|
||||
" +++ +++ ",
|
||||
" + ++++ ",
|
||||
" +++ + "};
|
BIN
src/musredit_qt5/images/musredit.icns
Normal file
BIN
src/musredit_qt5/images/musredit.ico
Normal file
After Width: | Height: | Size: 478 B |
BIN
src/musredit_qt5/images/musrfit-16x16.gif
Normal file
After Width: | Height: | Size: 99 B |
BIN
src/musredit_qt5/images/musrfit-16x16.ico
Normal file
After Width: | Height: | Size: 318 B |
BIN
src/musredit_qt5/images/musrfit-16x16.png
Normal file
After Width: | Height: | Size: 231 B |
22
src/musredit_qt5/images/musrfit-16x16.xpm
Normal file
@ -0,0 +1,22 @@
|
||||
/* XPM */
|
||||
static char * musrfit_16x16_xpm[] = {
|
||||
"16 16 3 1",
|
||||
" c None",
|
||||
". c #FF0000",
|
||||
"+ c #000000",
|
||||
" ... ",
|
||||
" +... . ",
|
||||
" .+ ...+. ",
|
||||
" ... . ... ",
|
||||
" ... ... ",
|
||||
" ... ... ",
|
||||
"+ . .+ ",
|
||||
" .+ ",
|
||||
" . ",
|
||||
" ... ",
|
||||
"+++ + +++ ... ",
|
||||
"+ + + ...+ ",
|
||||
"+++ + + . + ",
|
||||
"+ + + ...+",
|
||||
"+ + + ... ",
|
||||
" ... "};
|
BIN
src/musredit_qt5/images/musrfit.gif
Normal file
After Width: | Height: | Size: 5.9 KiB |
290
src/musredit_qt5/images/musrfit.svg
Normal file
@ -0,0 +1,290 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
||||
|
||||
<svg
|
||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
||||
xmlns:cc="http://creativecommons.org/ns#"
|
||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
||||
xmlns:svg="http://www.w3.org/2000/svg"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
||||
width="524.40942"
|
||||
height="372.04724"
|
||||
id="svg2"
|
||||
version="1.1"
|
||||
inkscape:version="0.47 r22583"
|
||||
sodipodi:docname="musrfit.svg">
|
||||
<defs
|
||||
id="defs4">
|
||||
<linearGradient
|
||||
id="linearGradient3649">
|
||||
<stop
|
||||
style="stop-color:#c8c8c8;stop-opacity:1;"
|
||||
offset="0"
|
||||
id="stop3651" />
|
||||
<stop
|
||||
style="stop-color:#ffffff;stop-opacity:0;"
|
||||
offset="1"
|
||||
id="stop3653" />
|
||||
</linearGradient>
|
||||
<inkscape:perspective
|
||||
sodipodi:type="inkscape:persp3d"
|
||||
inkscape:vp_x="0 : 526.18109 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_z="744.09448 : 526.18109 : 1"
|
||||
inkscape:persp3d-origin="372.04724 : 350.78739 : 1"
|
||||
id="perspective10" />
|
||||
<inkscape:perspective
|
||||
id="perspective3010"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3834"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3865"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3896"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3927"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3958"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
<inkscape:perspective
|
||||
id="perspective3665"
|
||||
inkscape:persp3d-origin="0.5 : 0.33333333 : 1"
|
||||
inkscape:vp_z="1 : 0.5 : 1"
|
||||
inkscape:vp_y="0 : 1000 : 0"
|
||||
inkscape:vp_x="0 : 0.5 : 1"
|
||||
sodipodi:type="inkscape:persp3d" />
|
||||
</defs>
|
||||
<sodipodi:namedview
|
||||
id="base"
|
||||
pagecolor="#ffffff"
|
||||
bordercolor="#666666"
|
||||
borderopacity="1.0"
|
||||
inkscape:pageopacity="0.0"
|
||||
inkscape:pageshadow="2"
|
||||
inkscape:zoom="2.1690794"
|
||||
inkscape:cx="190.97634"
|
||||
inkscape:cy="186.29563"
|
||||
inkscape:document-units="px"
|
||||
inkscape:current-layer="layer1"
|
||||
showgrid="false"
|
||||
inkscape:window-width="1920"
|
||||
inkscape:window-height="1030"
|
||||
inkscape:window-x="-4"
|
||||
inkscape:window-y="-3"
|
||||
inkscape:window-maximized="1" />
|
||||
<metadata
|
||||
id="metadata7">
|
||||
<rdf:RDF>
|
||||
<cc:Work
|
||||
rdf:about="">
|
||||
<dc:format>image/svg+xml</dc:format>
|
||||
<dc:type
|
||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
||||
<dc:title />
|
||||
</cc:Work>
|
||||
</rdf:RDF>
|
||||
</metadata>
|
||||
<g
|
||||
inkscape:label="Layer 1"
|
||||
inkscape:groupmode="layer"
|
||||
id="layer1"
|
||||
transform="translate(0,-680.31488)">
|
||||
<rect
|
||||
style="fill:#c8c864;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:0;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
|
||||
id="rect3647"
|
||||
width="405.38635"
|
||||
height="340.13422"
|
||||
x="54.14386"
|
||||
y="690.67322" />
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-size:40px;font-style:normal;font-weight:normal;fill:#ffffff;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans"
|
||||
x="143.41449"
|
||||
y="951.34796"
|
||||
id="text3016-4"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan3018-6"
|
||||
x="143.41449"
|
||||
y="951.34796"
|
||||
style="font-size:96px;font-weight:bold;fill:#ffffff;fill-opacity:1;font-family:CM Sans;-inkscape-font-specification:CM Sans Bold">FIT</tspan></text>
|
||||
<text
|
||||
xml:space="preserve"
|
||||
style="font-size:40px;font-style:normal;font-weight:normal;fill:#000000;fill-opacity:1;stroke:none;font-family:Bitstream Vera Sans"
|
||||
x="140.35832"
|
||||
y="947.95404"
|
||||
id="text3016"><tspan
|
||||
sodipodi:role="line"
|
||||
id="tspan3018"
|
||||
x="140.35832"
|
||||
y="947.95404"
|
||||
style="font-size:96px;font-weight:bold;font-family:CM Sans;-inkscape-font-specification:CM Sans Bold">FIT</tspan></text>
|
||||
<path
|
||||
style="fill:none;stroke:#000000;stroke-width:5;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none"
|
||||
d="m 166.07351,789.68979 c 0,0 5.53059,-9.03661 30.91685,-16.64754 25.38626,-7.61093 48.7535,35.6733 48.7535,35.6733 13.04598,27.30078 14.82377,35.16392 28.53864,47.56438 16.57186,14.98364 34.1988,9.42906 60.6446,28.53864 20.09704,14.522 26.16042,35.6733 26.16042,35.6733"
|
||||
id="path3020"
|
||||
sodipodi:nodetypes="czcasc" />
|
||||
<g
|
||||
id="g3821"
|
||||
transform="translate(34.411958,364.20129)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
<g
|
||||
id="g3821-8"
|
||||
transform="translate(69.411958,366.29912)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815-4"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817-6"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819-5"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
<g
|
||||
id="g3821-8-5"
|
||||
transform="translate(104.41196,396.0705)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815-4-5"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817-6-0"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819-5-9"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
<g
|
||||
id="g3821-8-5-3"
|
||||
transform="translate(139.41196,426.67611)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815-4-5-7"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817-6-0-8"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819-5-9-3"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
<g
|
||||
id="g3821-8-5-3-2"
|
||||
transform="translate(174.41196,463.92211)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815-4-5-7-2"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817-6-0-8-2"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819-5-9-3-8"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
<g
|
||||
id="g3821-8-5-3-2-8"
|
||||
transform="translate(209.41196,520.84722)">
|
||||
<path
|
||||
transform="matrix(0.80862041,0,0,0.80862041,24.230764,83.900652)"
|
||||
d="m 161.71894,403.10822 c 0,8.53745 -6.92097,15.45842 -15.45843,15.45842 -8.53745,0 -15.45842,-6.92097 -15.45842,-15.45842 0,-8.53746 6.92097,-15.45843 15.45842,-15.45843 8.53746,0 15.45843,6.92097 15.45843,15.45843 z"
|
||||
sodipodi:ry="15.458427"
|
||||
sodipodi:rx="15.458427"
|
||||
sodipodi:cy="403.10822"
|
||||
sodipodi:cx="146.26051"
|
||||
id="path3815-4-5-7-2-6"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke-width:5;stroke-miterlimit:4;stroke-dasharray:none"
|
||||
sodipodi:type="arc" />
|
||||
<path
|
||||
id="path3817-6-0-8-2-5"
|
||||
d="m 141.1961,374.75509 0,75.72405"
|
||||
style="fill:none;stroke:#000000;stroke-width:0.00099861px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
<path
|
||||
id="path3819-5-9-3-8-4"
|
||||
d="m 142.46542,383.0094 0,56.39595"
|
||||
style="fill:#ff0000;fill-opacity:1;stroke:#ff0000;stroke-width:4.16823864px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1" />
|
||||
</g>
|
||||
</g>
|
||||
</svg>
|
After Width: | Height: | Size: 12 KiB |
28
src/musredit_qt5/images/musrfit.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrfit_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #FF0000",
|
||||
"+ c #000000",
|
||||
" ... ",
|
||||
" +... . ",
|
||||
" .+ ...+. ",
|
||||
" ... . ... ",
|
||||
" ... ... ",
|
||||
" ... ... ",
|
||||
"+ . .+ ",
|
||||
" .+ ",
|
||||
" . ",
|
||||
" ... ",
|
||||
" ... . ",
|
||||
" ...+ . ",
|
||||
" . + ... ",
|
||||
" ...++... ",
|
||||
"++++ + +++++... ... ",
|
||||
"+ + + ... .+ ",
|
||||
"+ + + . ",
|
||||
"++++ + + ...",
|
||||
"+ + + ...",
|
||||
"+ + + ...",
|
||||
"+ + + . ",
|
||||
" "};
|
28
src/musredit_qt5/images/musrmsr2data.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrmlog2db_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #FF0000",
|
||||
" .... . ..... ",
|
||||
".... . . . ",
|
||||
" . . . ",
|
||||
".... ... . . ",
|
||||
" . . . ",
|
||||
"....... . . . ",
|
||||
" . . . ",
|
||||
".... ",
|
||||
" + ",
|
||||
"... + ",
|
||||
" + ",
|
||||
"...... + + + ",
|
||||
" +++ ",
|
||||
".... + ",
|
||||
" ",
|
||||
".... +++ +++ ",
|
||||
" + + + + ",
|
||||
"..... + + + + ",
|
||||
" + + +++ ",
|
||||
"...... + + + + ",
|
||||
" + + + + ",
|
||||
".... +++ +++ "};
|
28
src/musredit_qt5/images/musrprefs.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrprefs_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #3D20CF",
|
||||
"+ c #000000",
|
||||
"... ... ... ... ... ",
|
||||
". . . . . . . ",
|
||||
"... ... ... ... ... ",
|
||||
". . . . . . ",
|
||||
". . . ... . ... ",
|
||||
" ",
|
||||
" + + ",
|
||||
" + + + ",
|
||||
"+ ++++ ++ + ",
|
||||
" + + + + ",
|
||||
" + + ",
|
||||
" ",
|
||||
" + + ",
|
||||
" + + + ++ ++ + ",
|
||||
"+ + +++ + + + + + ",
|
||||
" + + + + ",
|
||||
" + + ",
|
||||
" ",
|
||||
" + + + ",
|
||||
" + + + + + ",
|
||||
"+ + +++++++++ + ++ +",
|
||||
" + ++ ++ + + "};
|
29
src/musredit_qt5/images/musrsinglehisto.xpm
Normal file
@ -0,0 +1,29 @@
|
||||
/* XPM */
|
||||
static char * musrsinglehisto_xpm[] = {
|
||||
"22 22 4 1",
|
||||
" c None",
|
||||
". c #3D20CF",
|
||||
"+ c #FF0000",
|
||||
"@ c #000000",
|
||||
" ",
|
||||
". . . .. ..... ... ",
|
||||
".++ . . . . . . .",
|
||||
". + . . . . . .",
|
||||
"..... . .. . . .",
|
||||
". +. . . . . .",
|
||||
". . . . . . . .",
|
||||
". .+. .. . ... ",
|
||||
"@ + ",
|
||||
"@ + ",
|
||||
"@ + ",
|
||||
"@ ++ ",
|
||||
"@ + ",
|
||||
"@ + ",
|
||||
"@ + ",
|
||||
"@ + ",
|
||||
"@ ++ ",
|
||||
"@ + ",
|
||||
"@ ++ ",
|
||||
"@ ++ ",
|
||||
"@ ++ ",
|
||||
"@@@@@@@@@@@@@@@@@@@+++"};
|
28
src/musredit_qt5/images/musrswap.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrswap_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #FF0000",
|
||||
".. .. .... .... ",
|
||||
".. .. . . . . ",
|
||||
". . . . . . . ",
|
||||
". ... . ... . . ",
|
||||
". . . .. .... ",
|
||||
". . . . . ",
|
||||
". . . . . . ",
|
||||
". . .+.. . . ",
|
||||
" +++ ",
|
||||
" +++++ ",
|
||||
" ++ + ++ ",
|
||||
" + ",
|
||||
" ++ + ++ ",
|
||||
" +++++ ",
|
||||
".. .. .+++... ... ",
|
||||
".. .. . +.. .. .. ..",
|
||||
". . . . . . . . .",
|
||||
". ... . . . . . ",
|
||||
". . . . . . . ...",
|
||||
". . . . . . .",
|
||||
". . . .. .. .. ..",
|
||||
". . ....... ... "};
|
28
src/musredit_qt5/images/musrt0.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrt0_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #3D20CF",
|
||||
"+ c #000000",
|
||||
"..... .. ",
|
||||
" . . . ",
|
||||
" . . . ",
|
||||
" . . . ",
|
||||
" . + . . ++ ",
|
||||
" . + . .+ ++ ",
|
||||
" . + .. + + ",
|
||||
" + + +++ ",
|
||||
" + + + ",
|
||||
" + + ++ ",
|
||||
" + + + ",
|
||||
" + + + ",
|
||||
" + + ++ ",
|
||||
" + + ++++ ",
|
||||
" + + + ",
|
||||
" + + ++",
|
||||
" + + ",
|
||||
" + + ",
|
||||
" + + ",
|
||||
" + ++ + ",
|
||||
"++ + + ",
|
||||
" "};
|
28
src/musredit_qt5/images/musrview.xpm
Normal file
@ -0,0 +1,28 @@
|
||||
/* XPM */
|
||||
static char * musrview_xpm[] = {
|
||||
"22 22 3 1",
|
||||
" c None",
|
||||
". c #000000",
|
||||
"+ c #FF0000",
|
||||
" .. ... .. ",
|
||||
" ",
|
||||
"......................",
|
||||
" . ",
|
||||
" . . ... ",
|
||||
" ++ . ",
|
||||
" ++ . ..... ",
|
||||
" + + . ",
|
||||
" + ... . ..... ",
|
||||
" + . + . . ",
|
||||
" +. + . . . ....",
|
||||
" +. + . . ",
|
||||
" + . + . . ... . ",
|
||||
" + . + . . ",
|
||||
" +. + . . ",
|
||||
" +. + ... ",
|
||||
" ++ . ",
|
||||
" . ",
|
||||
"......................",
|
||||
" ",
|
||||
" ....... .... .... ",
|
||||
" "};
|
BIN
src/musredit_qt5/latex_images/abragam.png
Normal file
After Width: | Height: | Size: 13 KiB |