Merge branch 'main' of http://git.hivekion.com:3000/jiayulong/logplus
This commit is contained in:
commit
f50c159113
|
|
@ -173,6 +173,13 @@ signals:
|
||||||
void sig_MergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
void sig_MergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
void sig_Merge_List(QString strUuid, QList<double> left_Low_List, QList<double> right_Hight_List);
|
void sig_Merge_List(QString strUuid, QList<double> left_Low_List, QList<double> right_Hight_List);
|
||||||
|
|
||||||
|
//执行预览
|
||||||
|
void sig_PreMergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
|
void sig_PreMerge_List(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> left_Low_List, QList<double> right_Hight_List);
|
||||||
|
void sig_PreMerge_FromRightList(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> new_DepthList, QList<double> new_ValueList);
|
||||||
|
//关闭预览框
|
||||||
|
void sig_PreMerge_Close(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
|
|
||||||
//Plot重新加载数据
|
//Plot重新加载数据
|
||||||
void sig_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName);
|
void sig_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,363 +0,0 @@
|
||||||
#pragma warning(push,0)
|
|
||||||
//#include "Family.h"
|
|
||||||
#include <QMessageBox>
|
|
||||||
#include <QObjectList>
|
|
||||||
#include <QLineEdit>
|
|
||||||
//#include "ObjectEvent.h"
|
|
||||||
#include "CurvePropertyEdit.h"
|
|
||||||
#include "ui_CurvePropertyEdit.h"
|
|
||||||
#include "CStringType.h"
|
|
||||||
#include "LogIO.h"
|
|
||||||
//#include "ObjProject.h"
|
|
||||||
#include "ui_CurvePropertyEdit.h"
|
|
||||||
#pragma warning(pop)
|
|
||||||
extern char *DataTypea[];
|
|
||||||
extern int DataLengtha[];
|
|
||||||
|
|
||||||
CCurvePropertyEditDlg::CCurvePropertyEditDlg(QWidget * parent, Qt::WindowFlags flags)
|
|
||||||
: QWidget(parent,flags)
|
|
||||||
{
|
|
||||||
m_pUI = new Ui::CurvePropertyEdit();
|
|
||||||
m_pUI->setupUi(this);
|
|
||||||
int w=width();
|
|
||||||
int h=height();
|
|
||||||
if(NULL != parent)
|
|
||||||
{
|
|
||||||
parent->setFixedSize(w,h);
|
|
||||||
}
|
|
||||||
|
|
||||||
QObject::connect(m_pUI->okbtn, SIGNAL(clicked()), this, SLOT(slotSave()));
|
|
||||||
QObject::connect(m_pUI->cancelbtn, SIGNAL(clicked()), this, SLOT(slotCancel()));
|
|
||||||
tab1=m_pUI->PropertyTab->widget(0);
|
|
||||||
tab2=m_pUI->PropertyTab->widget(1);
|
|
||||||
m_pUI->PropertyTab->setCurrentIndex(0);
|
|
||||||
m_pUI->cancelbtn->hide();
|
|
||||||
/* QObjectList ctls=tab1->children();
|
|
||||||
QLineEdit* liedit=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
liedit->setText("11");
|
|
||||||
//foreach (QObject* ctl,ctls)
|
|
||||||
//{
|
|
||||||
// if (ctl->objectName()=="lineEdit_CurveName")
|
|
||||||
// {
|
|
||||||
// QLineEdit* liedit= (QLineEdit*)(ctl);
|
|
||||||
// liedit->setText("11");
|
|
||||||
|
|
||||||
// }
|
|
||||||
//}
|
|
||||||
QObjectList ctls2=tab2->children();
|
|
||||||
foreach (QObject* ctl,ctls2)
|
|
||||||
{
|
|
||||||
if (ctl->objectName()=="lineEdit2_ArrayNum")
|
|
||||||
{
|
|
||||||
QLineEdit* liedit= (QLineEdit*)(ctl);
|
|
||||||
liedit->setText("444");
|
|
||||||
|
|
||||||
}
|
|
||||||
}*/
|
|
||||||
}
|
|
||||||
void CCurvePropertyEditDlg::init()
|
|
||||||
{
|
|
||||||
|
|
||||||
//初始化
|
|
||||||
CLogIO logio(FileName.toStdString().c_str(),(unsigned int)CLogIO::modeReadWrite);
|
|
||||||
if(!logio.mFile) return ;
|
|
||||||
int c=12;
|
|
||||||
QString str;
|
|
||||||
for(int i=0;i<c;i++) {
|
|
||||||
if(!i)str+="[";
|
|
||||||
else str+="|[";
|
|
||||||
str+=Rep_STR[i];
|
|
||||||
str+="]";
|
|
||||||
};
|
|
||||||
QRegExp regExp("[A-Z0-9]{0,100}");//正则表达式,第一位数字为a-z的数字,第二位为1-9的数字,后边是0-2位0-9的数字
|
|
||||||
|
|
||||||
if(Type==0)
|
|
||||||
{
|
|
||||||
m_pUI->PropertyTab->setTabEnabled(1,0);
|
|
||||||
m_pUI->PropertyTab->setStyleSheet("QTabBar::tab:disabled {width: 0; color: transparent;}");
|
|
||||||
Slf_CURVE info;
|
|
||||||
int index=logio.OpenCurve(CurveName.toStdString().c_str());
|
|
||||||
if(index<0) return;
|
|
||||||
logio.GetCurveInfo(index,&info);
|
|
||||||
logio.CloseCurve(index);
|
|
||||||
QLineEdit *lineEdit_CurveName=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
QLineEdit *lineEdit_CurveName_2=tab1->findChild<QLineEdit*>("lineEdit_CurveName_2");
|
|
||||||
QLineEdit *lineEdit_CurveUnit=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit");
|
|
||||||
QLineEdit *lineEdit_CurveUnit_2=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit_2");
|
|
||||||
QLineEdit *lineEdit_DepthUnit=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit");
|
|
||||||
QLineEdit *lineEdit_DepthUnit_2=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit_2");
|
|
||||||
QLineEdit *lineEdit_Sdep=tab1->findChild<QLineEdit*>("lineEdit_Sdep");
|
|
||||||
QLineEdit *lineEdit_Edep=tab1->findChild<QLineEdit*>("lineEdit_Edep");
|
|
||||||
QLineEdit *lineEdit_Rlev=tab1->findChild<QLineEdit*>("lineEdit_Rlev");
|
|
||||||
QLineEdit *lineEdit_DataType=tab1->findChild<QLineEdit*>("lineEdit_DataType");
|
|
||||||
QLineEdit *lineEdit_Min=tab1->findChild<QLineEdit*>("lineEdit_Min");
|
|
||||||
QLineEdit *lineEdit_Max=tab1->findChild<QLineEdit*>("lineEdit_Max");
|
|
||||||
QLineEdit *lineEdit_DefVal=tab1->findChild<QLineEdit*>("lineEdit_DefVal");
|
|
||||||
lineEdit_CurveName->setText((QLatin1String(info.Name)));
|
|
||||||
QRegExp regExp("[A-Z0-9]{0,100}");//正则表达式,第一位数字为a-z的数字,第二位为1-9的数字,后边是0-2位0-9的数字
|
|
||||||
lineEdit_CurveName->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveName_2->setText(QString::fromLocal8Bit(info.AliasName));
|
|
||||||
lineEdit_CurveName_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveUnit->setText(QLatin1String(info.Unit));
|
|
||||||
lineEdit_CurveUnit->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveUnit_2->setText(QString::fromLocal8Bit(info.AliasUnit));//(QLatin1String(info.AliasUnit));
|
|
||||||
lineEdit_CurveUnit_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_DepthUnit->setText(QLatin1String(info.DepthUnit));
|
|
||||||
lineEdit_DepthUnit->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_DepthUnit_2->setText(QString::fromLocal8Bit(info.DepthHZUnit));
|
|
||||||
lineEdit_DepthUnit_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_Sdep->setText(QString("%1").arg(info.StartDepth));
|
|
||||||
lineEdit_Sdep->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Edep->setText(QString("%1").arg(info.EndDepth));
|
|
||||||
lineEdit_Edep->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Rlev->setText(QString("%1").arg(info.DepLevel));
|
|
||||||
lineEdit_Rlev->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
regExp=QRegExp(str);
|
|
||||||
lineEdit_DataType->setText(QLatin1String(Rep_STR[info.RepCode-1]));
|
|
||||||
lineEdit_Sdep->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_Min->setText(QString("%1").arg(info.MinValue));
|
|
||||||
lineEdit_Min->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Max->setText(QString("%1").arg(info.MaxValue));
|
|
||||||
lineEdit_Max->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_DefVal->setText(QString("%1").arg(info.DefVal));
|
|
||||||
lineEdit_DefVal->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
int index=logio.OpenWave(CurveName.toStdString().c_str());
|
|
||||||
if(index<0) return;
|
|
||||||
Slf_WAVE info;
|
|
||||||
logio.GetWaveInfo(index,&info);
|
|
||||||
logio.CloseWave(index);
|
|
||||||
if(info.RepCode>12) return;
|
|
||||||
QLineEdit *lineEdit_CurveName=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
QLineEdit *lineEdit_CurveName_2=tab1->findChild<QLineEdit*>("lineEdit_CurveName_2");
|
|
||||||
QLineEdit *lineEdit_CurveUnit=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit");
|
|
||||||
QLineEdit *lineEdit_CurveUnit_2=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit_2");
|
|
||||||
QLineEdit *lineEdit_DepthUnit=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit");
|
|
||||||
QLineEdit *lineEdit_DepthUnit_2=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit_2");
|
|
||||||
QLineEdit *lineEdit_Sdep=tab1->findChild<QLineEdit*>("lineEdit_Sdep");
|
|
||||||
QLineEdit *lineEdit_Edep=tab1->findChild<QLineEdit*>("lineEdit_Edep");
|
|
||||||
QLineEdit *lineEdit_Rlev=tab1->findChild<QLineEdit*>("lineEdit_Rlev");
|
|
||||||
QLineEdit *lineEdit_DataType=tab1->findChild<QLineEdit*>("lineEdit_DataType");
|
|
||||||
QLineEdit *lineEdit_Min=tab1->findChild<QLineEdit*>("lineEdit_Min");
|
|
||||||
QLineEdit *lineEdit_Max=tab1->findChild<QLineEdit*>("lineEdit_Max");
|
|
||||||
QLineEdit *lineEdit_DefVal=tab1->findChild<QLineEdit*>("lineEdit_DefVal");
|
|
||||||
lineEdit_CurveName->setText((QLatin1String(info.Name)));
|
|
||||||
lineEdit_CurveName->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveName_2->setText(QString::fromLocal8Bit(info.AliasName));
|
|
||||||
lineEdit_CurveName_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveUnit->setText(QLatin1String(info.Unit));
|
|
||||||
lineEdit_CurveUnit->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_CurveUnit_2->setText(QString::fromLocal8Bit(info.AliasUnit));
|
|
||||||
lineEdit_CurveUnit_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_DepthUnit->setText(QLatin1String(info.DepthUnit));
|
|
||||||
lineEdit_DepthUnit->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_DepthUnit_2->setText(QString::fromLocal8Bit(info.DepthHZUnit));
|
|
||||||
lineEdit_DepthUnit_2->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit_Sdep->setText(QString("%1").arg(info.StartDepth));
|
|
||||||
lineEdit_Sdep->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Edep->setText(QString("%1").arg(info.EndDepth));
|
|
||||||
lineEdit_Edep->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Rlev->setText(QString("%1").arg(info.DepLevel));
|
|
||||||
lineEdit_Rlev->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
regExp=QRegExp(str);
|
|
||||||
lineEdit_DataType->setText(QLatin1String(Rep_STR[info.RepCode-1]));
|
|
||||||
lineEdit_Min->setText(QString("%1").arg(info.MinValue));
|
|
||||||
lineEdit_Min->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_Max->setText(QString("%1").arg(info.MaxValue));
|
|
||||||
lineEdit_Max->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit_DefVal->setText(QString("%1").arg(info.DefVal));
|
|
||||||
lineEdit_DefVal->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
|
|
||||||
QLineEdit *lineEdit2_Name=tab2->findChild<QLineEdit*>("lineEdit2_Name");
|
|
||||||
QLineEdit *lineEdit2_Name1=tab2->findChild<QLineEdit*>("lineEdit2_Name1");
|
|
||||||
QLineEdit *lineEdit2_Unit=tab2->findChild<QLineEdit*>("lineEdit2_Unit");
|
|
||||||
QLineEdit *lineEdit2_Unit1=tab2->findChild<QLineEdit*>("lineEdit2_Unit1");
|
|
||||||
QLineEdit *lineEdit2_Start=tab2->findChild<QLineEdit*>("lineEdit2_Start");
|
|
||||||
QLineEdit *lineEdit2_Rlev2=tab2->findChild<QLineEdit*>("lineEdit2_Rlev2");
|
|
||||||
QLineEdit *lineEdit2_ArrayNum=tab2->findChild<QLineEdit*>("lineEdit2_ArrayNum");
|
|
||||||
QLineEdit *lineEdit2_Sample=tab2->findChild<QLineEdit*>("lineEdit2_Sample");
|
|
||||||
QLineEdit *lineEdit2_SampleTotal=tab2->findChild<QLineEdit*>("lineEdit2_SampleTotal");
|
|
||||||
QComboBox *comboBox2_Type=tab2->findChild<QComboBox*>("comboBox2_Type");
|
|
||||||
comboBox2_Type->addItem(QString::fromLocal8Bit("线性刻度"));
|
|
||||||
comboBox2_Type->addItem(QString::fromLocal8Bit("对数刻度"));
|
|
||||||
comboBox2_Type->addItem(QString::fromLocal8Bit("指数刻度"));
|
|
||||||
comboBox2_Type->setCurrentIndex(0);
|
|
||||||
QObject::connect(lineEdit2_ArrayNum, SIGNAL(textChanged(const QString &)), this, SLOT(sampleChanged(const QString &)));
|
|
||||||
QObject::connect(lineEdit2_Sample, SIGNAL(textChanged(const QString &)), this, SLOT(arrayChanged(const QString &)));
|
|
||||||
QRegExp regExp("[A-Za-z0-9]{0,100}");//正则表达式,第一位数字为a-z的数字,第二位为1-9的数字,后边是0-2位0-9的数字
|
|
||||||
lineEdit2_Name->setText(QLatin1String(info.TimeName));
|
|
||||||
lineEdit2_Name->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit2_Name1->setText(QString::fromLocal8Bit(info.TimeHZName));
|
|
||||||
lineEdit2_Name1->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit2_Unit->setText(QLatin1String(info.TimeUnit));
|
|
||||||
lineEdit2_Unit->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
lineEdit2_Unit1->setText(QString::fromLocal8Bit(info.TimeHZUnit));
|
|
||||||
lineEdit2_Unit1->setValidator(new QRegExpValidator(regExp,this));
|
|
||||||
|
|
||||||
lineEdit2_Start->setText(QString("%1").arg(info.StartTime));
|
|
||||||
lineEdit2_Start->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit2_Rlev2->setText(QString("%1").arg(info.TimeLevel));
|
|
||||||
lineEdit2_Rlev2->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
lineEdit2_ArrayNum->setText(QString("%1").arg(info.ArrayNum));
|
|
||||||
lineEdit2_ArrayNum->setValidator(new QIntValidator(0,9999999,this));
|
|
||||||
lineEdit2_Sample->setText(QString("%1").arg(info.TimeSamples));
|
|
||||||
lineEdit2_Sample->setValidator(new QIntValidator(0,9999999,this));
|
|
||||||
lineEdit2_SampleTotal->setText(QString("%1").arg(info.TimeSamples));
|
|
||||||
lineEdit2_SampleTotal->setValidator(new QIntValidator(0,99999999,this));
|
|
||||||
}
|
|
||||||
logio.Close();
|
|
||||||
}
|
|
||||||
void CCurvePropertyEditDlg::sampleChanged(const QString &str)
|
|
||||||
{
|
|
||||||
QLineEdit *lineEdit2_Sample=tab2->findChild<QLineEdit*>("lineEdit2_Sample");
|
|
||||||
QLineEdit *lineEdit2_SampleTotal=tab2->findChild<QLineEdit*>("lineEdit2_SampleTotal");
|
|
||||||
|
|
||||||
int TotalSample=lineEdit2_SampleTotal->text().toInt();
|
|
||||||
int mSample=lineEdit2_Sample->text().toInt();
|
|
||||||
if(TotalSample==0)return;
|
|
||||||
int arrayNum=str.toInt();
|
|
||||||
int sample=TotalSample;
|
|
||||||
if(sample!=TotalSample)
|
|
||||||
{
|
|
||||||
QMessageBox::warning(NULL,"提示","阵列数不是总元素个数的公约数,请重新输入");
|
|
||||||
QLineEdit *lineEdit2_ArrayNum=tab2->findChild<QLineEdit*>("lineEdit2_ArrayNum");
|
|
||||||
lineEdit2_ArrayNum->setText(QString::number(TotalSample/mSample));
|
|
||||||
}
|
|
||||||
else lineEdit2_Sample->setText(QString::number(sample));
|
|
||||||
}
|
|
||||||
void CCurvePropertyEditDlg::arrayChanged(const QString &str)
|
|
||||||
{
|
|
||||||
QLineEdit *lineEdit2_ArrayNum=tab2->findChild<QLineEdit*>("lineEdit2_ArrayNum");
|
|
||||||
QLineEdit *lineEdit2_SampleTotal=tab2->findChild<QLineEdit*>("lineEdit2_SampleTotal");
|
|
||||||
|
|
||||||
int TotalSample=lineEdit2_SampleTotal->text().toInt();
|
|
||||||
int mArrayNum=lineEdit2_ArrayNum->text().toInt();
|
|
||||||
if(TotalSample==0)return;
|
|
||||||
int sample=str.toInt();
|
|
||||||
int arrayNum=TotalSample/sample;
|
|
||||||
if(arrayNum*sample!=TotalSample)
|
|
||||||
{
|
|
||||||
QMessageBox::warning(this,"提示","您所输入的元素个数不是总元素个数的公约数,请重新输入");
|
|
||||||
QLineEdit *lineEdit2_Sample=tab2->findChild<QLineEdit*>("lineEdit2_Sample");
|
|
||||||
lineEdit2_Sample->setText(QString::number(TotalSample/mArrayNum));
|
|
||||||
}
|
|
||||||
else lineEdit2_ArrayNum->setText(QString::number(arrayNum));
|
|
||||||
}
|
|
||||||
void CCurvePropertyEditDlg::slotSave()
|
|
||||||
{
|
|
||||||
QLineEdit *lineEdit_CurveName=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
QString Name=lineEdit_CurveName->text();
|
|
||||||
CLogIO logio(FileName.toStdString().c_str(),(unsigned int)CLogIO::modeReadWrite);
|
|
||||||
if(Name!=CurveName)
|
|
||||||
{
|
|
||||||
if(logio.FindObjectIndex(Name.toStdString().c_str())>=0)
|
|
||||||
{
|
|
||||||
QMessageBox::warning(this,"警告!","名称不能重复!");
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Slf_FILE_MESSAGE ms;
|
|
||||||
logio.GetFileMessage(ms);
|
|
||||||
if(Type==0)
|
|
||||||
{
|
|
||||||
Slf_CURVE info;
|
|
||||||
int index=logio.OpenCurve(CurveName.toStdString().c_str());
|
|
||||||
if(index<0) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
logio.GetCurveInfo(index,&info);
|
|
||||||
QLineEdit *lineEdit_CurveName=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
QLineEdit *lineEdit_CurveName_2=tab1->findChild<QLineEdit*>("lineEdit_CurveName_2");
|
|
||||||
QLineEdit *lineEdit_CurveUnit=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit");
|
|
||||||
QLineEdit *lineEdit_CurveUnit_2=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit_2");
|
|
||||||
QLineEdit *lineEdit_DepthUnit=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit");
|
|
||||||
QLineEdit *lineEdit_DepthUnit_2=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit_2");
|
|
||||||
|
|
||||||
QLineEdit *lineEdit_DefVal=tab1->findChild<QLineEdit*>("lineEdit_DefVal");
|
|
||||||
strcpy(info.Name,lineEdit_CurveName->text().toStdString().c_str());
|
|
||||||
strcpy(info.AliasName,lineEdit_CurveName_2->text().toStdString().c_str());
|
|
||||||
//汉字写回去不对了呀??????
|
|
||||||
strcpy(info.Unit,lineEdit_CurveUnit->text().toStdString().c_str());
|
|
||||||
strcpy(info.AliasUnit,lineEdit_CurveUnit_2->text().toStdString().c_str());
|
|
||||||
strcpy(info.DepthUnit,lineEdit_DepthUnit->text().toStdString().c_str());
|
|
||||||
strcpy(info.DepthHZUnit,lineEdit_DepthUnit_2->text().toStdString().c_str());
|
|
||||||
info.DefVal=lineEdit_DefVal->text().toFloat();
|
|
||||||
logio.SetCurveInfo(index,&info);
|
|
||||||
logio.CloseCurve(index);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
int index=logio.OpenWave(CurveName.toStdString().c_str());
|
|
||||||
if(index<0) return;
|
|
||||||
Slf_WAVE info;
|
|
||||||
logio.GetWaveInfo(index,&info);
|
|
||||||
|
|
||||||
QLineEdit *lineEdit_CurveName=tab1->findChild<QLineEdit*>("lineEdit_CurveName");
|
|
||||||
QLineEdit *lineEdit_CurveName_2=tab1->findChild<QLineEdit*>("lineEdit_CurveName_2");
|
|
||||||
QLineEdit *lineEdit_CurveUnit=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit");
|
|
||||||
QLineEdit *lineEdit_CurveUnit_2=tab1->findChild<QLineEdit*>("lineEdit_CurveUnit_2");
|
|
||||||
QLineEdit *lineEdit_DepthUnit=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit");
|
|
||||||
QLineEdit *lineEdit_DepthUnit_2=tab1->findChild<QLineEdit*>("lineEdit_DepthUnit_2");
|
|
||||||
|
|
||||||
QLineEdit *lineEdit_DefVal=tab1->findChild<QLineEdit*>("lineEdit_DefVal");
|
|
||||||
strcpy(info.Name,lineEdit_CurveName->text().toStdString().c_str());
|
|
||||||
strcpy(info.AliasName,lineEdit_CurveName_2->text().toStdString().c_str());
|
|
||||||
strcpy(info.Unit,lineEdit_CurveUnit->text().toStdString().c_str());
|
|
||||||
strcpy(info.AliasUnit,lineEdit_CurveUnit_2->text().toStdString().c_str());
|
|
||||||
strcpy(info.DepthUnit,lineEdit_DepthUnit->text().toStdString().c_str());
|
|
||||||
strcpy(info.DepthHZUnit,lineEdit_DepthUnit_2->text().toStdString().c_str());
|
|
||||||
info.DefVal=lineEdit_DefVal->text().toFloat();
|
|
||||||
|
|
||||||
QLineEdit *lineEdit2_Name=tab2->findChild<QLineEdit*>("lineEdit2_Name");
|
|
||||||
QLineEdit *lineEdit2_Name1=tab2->findChild<QLineEdit*>("lineEdit2_Name1");
|
|
||||||
QLineEdit *lineEdit2_Unit=tab2->findChild<QLineEdit*>("lineEdit2_Unit");
|
|
||||||
QLineEdit *lineEdit2_Unit1=tab2->findChild<QLineEdit*>("lineEdit2_Unit1");
|
|
||||||
QLineEdit *lineEdit2_Start=tab2->findChild<QLineEdit*>("lineEdit2_Start");
|
|
||||||
QLineEdit *lineEdit2_Rlev2=tab2->findChild<QLineEdit*>("lineEdit2_Rlev2");
|
|
||||||
QLineEdit *lineEdit2_ArrayNum=tab2->findChild<QLineEdit*>("lineEdit2_ArrayNum");
|
|
||||||
QLineEdit *lineEdit2_Sample=tab2->findChild<QLineEdit*>("lineEdit2_Sample");
|
|
||||||
QLineEdit *lineEdit2_SampleTotal=tab2->findChild<QLineEdit*>("lineEdit2_SampleTotal");
|
|
||||||
QComboBox *comboBox2_Type=tab2->findChild<QComboBox*>("comboBox2_Type");
|
|
||||||
|
|
||||||
strcpy(info.TimeName,lineEdit2_Name->text().toStdString().c_str());
|
|
||||||
strcpy(info.TimeHZName,lineEdit2_Name1->text().toStdString().c_str());
|
|
||||||
strcpy(info.TimeUnit,lineEdit2_Unit->text().toStdString().c_str());
|
|
||||||
strcpy(info.TimeHZUnit,lineEdit2_Unit1->text().toStdString().c_str());
|
|
||||||
info.StartTime=lineEdit2_Start->text().toFloat();
|
|
||||||
info.TimeLevel=lineEdit2_Rlev2->text().toFloat();
|
|
||||||
info.ArrayNum=lineEdit2_ArrayNum->text().toInt();
|
|
||||||
info.TimeSamples=lineEdit2_Sample->text().toInt();
|
|
||||||
logio.SetWaveInfo(index,&info);
|
|
||||||
logio.CloseWave(index);
|
|
||||||
}
|
|
||||||
logio.Close();
|
|
||||||
//GetObjectEvent().OnDeAttchData(FileName,CurveName);
|
|
||||||
//GetObjectEvent().OnRefreshData(FileName,CurveName);
|
|
||||||
if(Name!=CurveName)
|
|
||||||
{
|
|
||||||
QStringList NodeNames;
|
|
||||||
NodeNames.push_back(ms.WellName);
|
|
||||||
NodeNames.push_back(FileName);
|
|
||||||
NodeNames.push_back(CurveName);
|
|
||||||
NodeNames.push_back(Name);
|
|
||||||
//PaiObject::m_EventAgent.ObjectPropertyChanged(GetProject(),"CurvePropertyEdit",NodeNames);
|
|
||||||
}
|
|
||||||
QMessageBox::information(this,"提示","保存成功!");
|
|
||||||
//accept();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
*@brief 取消槽函数
|
|
||||||
*/
|
|
||||||
void CCurvePropertyEditDlg::slotCancel()
|
|
||||||
{
|
|
||||||
//reject ();
|
|
||||||
}
|
|
||||||
|
|
||||||
void CCurvePropertyEditDlg::closeEvent(QCloseEvent *)
|
|
||||||
{
|
|
||||||
emit signalsCloseed();
|
|
||||||
//throw std::logic_error("The method or operation is not implemented.");
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
@ -1,49 +0,0 @@
|
||||||
|
|
||||||
#pragma warning(push,0)
|
|
||||||
#include <cassert>
|
|
||||||
#include <QWidget>
|
|
||||||
#include <QDialog>
|
|
||||||
//#include "ConsoleOutputWidget.h"
|
|
||||||
#pragma warning(pop)
|
|
||||||
|
|
||||||
namespace Ui {
|
|
||||||
class CurvePropertyEdit;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @brief 表格选择列自定义委托
|
|
||||||
*/
|
|
||||||
class CCurvePropertyEditDlg : public QWidget
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
public:
|
|
||||||
CCurvePropertyEditDlg(QWidget * parent=0, Qt::WindowFlags flags=0);
|
|
||||||
~CCurvePropertyEditDlg()
|
|
||||||
{
|
|
||||||
if(m_pUI) delete m_pUI;
|
|
||||||
}
|
|
||||||
Ui::CurvePropertyEdit *m_pUI;
|
|
||||||
void init();
|
|
||||||
signals:
|
|
||||||
void signalsCloseed();
|
|
||||||
private slots:
|
|
||||||
/**
|
|
||||||
*@brief 保存槽函数
|
|
||||||
*/
|
|
||||||
void slotSave();
|
|
||||||
|
|
||||||
/**
|
|
||||||
*@brief 取消槽函数*/
|
|
||||||
void slotCancel();
|
|
||||||
void sampleChanged(const QString &);
|
|
||||||
void arrayChanged(const QString &);
|
|
||||||
|
|
||||||
virtual void closeEvent(QCloseEvent *);
|
|
||||||
|
|
||||||
public:
|
|
||||||
QString FileName;//slf文件名
|
|
||||||
QString CurveName;//曲线名
|
|
||||||
int Type;//曲线类型,0-曲线,1-波列
|
|
||||||
QWidget* tab1;
|
|
||||||
QWidget* tab2;
|
|
||||||
};
|
|
||||||
|
|
@ -1,525 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<ui version="4.0">
|
|
||||||
<class>CurvePropertyEdit</class>
|
|
||||||
<widget class="QWidget" name="CurvePropertyEdit">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>665</width>
|
|
||||||
<height>575</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>曲线属性显示与编辑</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
|
||||||
<item>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="QTabWidget" name="PropertyTab">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="currentIndex">
|
|
||||||
<number>0</number>
|
|
||||||
</property>
|
|
||||||
<widget class="QWidget" name="CurveTab">
|
|
||||||
<attribute name="title">
|
|
||||||
<string>曲线属性</string>
|
|
||||||
</attribute>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线名</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_CurveName">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_2">
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线别名</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_CurveName_2">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_3">
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线单位</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_CurveUnit">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_4">
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线别单位</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_CurveUnit_2">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
|
||||||
<widget class="QLabel" name="label_5">
|
|
||||||
<property name="text">
|
|
||||||
<string>深度单位</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_DepthUnit">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2">
|
|
||||||
<widget class="QLabel" name="label_6">
|
|
||||||
<property name="text">
|
|
||||||
<string>深度单位别名</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_DepthUnit_2">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QLabel" name="label_7">
|
|
||||||
<property name="text">
|
|
||||||
<string>起始深度</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Sdep">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="2">
|
|
||||||
<widget class="QLabel" name="label_8">
|
|
||||||
<property name="text">
|
|
||||||
<string>终止深度</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Edep">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0">
|
|
||||||
<widget class="QLabel" name="label_9">
|
|
||||||
<property name="text">
|
|
||||||
<string>采样间隔</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Rlev">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="2">
|
|
||||||
<widget class="QLabel" name="label_10">
|
|
||||||
<property name="text">
|
|
||||||
<string>数据类型</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_DataType">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="0">
|
|
||||||
<widget class="QLabel" name="label_11">
|
|
||||||
<property name="text">
|
|
||||||
<string>最小值</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Min">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="2">
|
|
||||||
<widget class="QLabel" name="label_12">
|
|
||||||
<property name="text">
|
|
||||||
<string>最大值</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Max">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="0">
|
|
||||||
<widget class="QLabel" name="label_13">
|
|
||||||
<property name="text">
|
|
||||||
<string>缺省值</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit_DefVal">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<widget class="QWidget" name="WaveTab">
|
|
||||||
<attribute name="title">
|
|
||||||
<string>波列属性</string>
|
|
||||||
</attribute>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
|
||||||
<item row="0" column="0">
|
|
||||||
<widget class="QLabel" name="label_17">
|
|
||||||
<property name="text">
|
|
||||||
<string>名称</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Name">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="2">
|
|
||||||
<widget class="QLabel" name="label_16">
|
|
||||||
<property name="text">
|
|
||||||
<string>别名</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="0" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Name1">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="0">
|
|
||||||
<widget class="QLabel" name="label_15">
|
|
||||||
<property name="text">
|
|
||||||
<string>单位</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Unit">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<widget class="QLabel" name="label_23">
|
|
||||||
<property name="text">
|
|
||||||
<string>单位别名</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Unit1">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
|
||||||
<widget class="QLabel" name="label_20">
|
|
||||||
<property name="text">
|
|
||||||
<string>起始值</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Start">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2">
|
|
||||||
<widget class="QLabel" name="label_18">
|
|
||||||
<property name="text">
|
|
||||||
<string>增量</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Rlev2">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QLabel" name="label_22">
|
|
||||||
<property name="text">
|
|
||||||
<string>阵列数</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_ArrayNum">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="2">
|
|
||||||
<widget class="QLabel" name="label_21">
|
|
||||||
<property name="text">
|
|
||||||
<string>刻度类型</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="3">
|
|
||||||
<widget class="QComboBox" name="comboBox2_Type">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0">
|
|
||||||
<widget class="QLabel" name="label_19">
|
|
||||||
<property name="text">
|
|
||||||
<string>元素个数</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="1">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_Sample">
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="2">
|
|
||||||
<widget class="QLabel" name="label_14">
|
|
||||||
<property name="text">
|
|
||||||
<string>总元素个数</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="3">
|
|
||||||
<widget class="QLineEdit" name="lineEdit2_SampleTotal">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>false</bool>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>30</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
|
||||||
<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">
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="okbtn">
|
|
||||||
<property name="text">
|
|
||||||
<string>保存</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="cancelbtn">
|
|
||||||
<property name="text">
|
|
||||||
<string>退出</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="horizontalSpacer_3">
|
|
||||||
<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>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<resources/>
|
|
||||||
<connections/>
|
|
||||||
</ui>
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,157 +0,0 @@
|
||||||
#ifndef DRAWCURVEVIEW_H
|
|
||||||
#define DRAWCURVEVIEW_H
|
|
||||||
|
|
||||||
#include <QWidget>
|
|
||||||
#include <QPaintEvent>
|
|
||||||
#include "qpushbutton.h"
|
|
||||||
//#include "DataManagger.h"
|
|
||||||
#include "SmoothTool.h"
|
|
||||||
#include "AngleAdjTool.h"
|
|
||||||
#include "editEnd.h"
|
|
||||||
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
|
|
||||||
//视图边距
|
|
||||||
#define D_VIEW_MARGIN_LEFT 80//左、下边界
|
|
||||||
#define D_VIEW_MARGIN_BOTTOM 30//左、下边界
|
|
||||||
#define D_VIEW_MARGIN_RIGHT 40//右、上边界
|
|
||||||
#define D_VIEW_MARGIN_TOP 25//上边界
|
|
||||||
|
|
||||||
|
|
||||||
class DrawCurveView : public QWidget
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
public:
|
|
||||||
explicit DrawCurveView(QWidget *parent = nullptr);
|
|
||||||
~DrawCurveView();
|
|
||||||
void initView();
|
|
||||||
void setValues(float *values);
|
|
||||||
void setCount(int count);
|
|
||||||
|
|
||||||
signals:
|
|
||||||
void enableEditButtons();
|
|
||||||
void unableEditButtons();
|
|
||||||
void R2L();
|
|
||||||
void verticalSliderUP();
|
|
||||||
void verticalSliderDOWN();
|
|
||||||
void editModeTips();
|
|
||||||
|
|
||||||
public slots:
|
|
||||||
void editIfBegin_Slot();
|
|
||||||
void smoothWin_Slot();
|
|
||||||
void finishEdit_SLOT();
|
|
||||||
void AngAdjWin_SLOT();
|
|
||||||
void overEditSave();
|
|
||||||
|
|
||||||
private slots:
|
|
||||||
void receiveSmoothData(float sd, float ed, int mode, int cal, int count);
|
|
||||||
void cancelSmoothEdit();
|
|
||||||
void saveSmooth_SLOT(int);
|
|
||||||
void receiveAngleData(float,float,float,float,float);
|
|
||||||
void cancelAngleEdit();
|
|
||||||
|
|
||||||
void continueEditNoSave_SLOT();
|
|
||||||
protected:
|
|
||||||
virtual void paintEvent(QPaintEvent *evt);
|
|
||||||
virtual void mouseMoveEvent(QMouseEvent *event);
|
|
||||||
virtual void mousePressEvent(QMouseEvent *event);
|
|
||||||
virtual void mouseReleaseEvent(QMouseEvent *event);
|
|
||||||
virtual void wheelEvent(QWheelEvent *event);
|
|
||||||
private:
|
|
||||||
//绘制坐标
|
|
||||||
void drawCoord(QPainter *painter);
|
|
||||||
|
|
||||||
//波列数据转换为图像坐标
|
|
||||||
QPointF coordCurvePoint(int ix,float value);
|
|
||||||
|
|
||||||
//绘制波列数据点
|
|
||||||
void drawDataPoints(QPainter *painter);
|
|
||||||
|
|
||||||
//绘制鼠标位置线
|
|
||||||
void drawMousePosLine(QPainter *painter);
|
|
||||||
|
|
||||||
//绘制鼠标单点
|
|
||||||
void usevalueDrawPoint(QPainter *painter);
|
|
||||||
|
|
||||||
//曲线操作
|
|
||||||
void initCurveViewQMenu();
|
|
||||||
void initCurveEditQMenu();
|
|
||||||
|
|
||||||
//获取当前鼠标位置的曲线下标
|
|
||||||
int calMousePoint();
|
|
||||||
|
|
||||||
//绘制编辑模式提示字符
|
|
||||||
void drawEditTishi(QPainter *painter);
|
|
||||||
|
|
||||||
void editIfBegin();
|
|
||||||
void initEditPart();//初始化编辑块
|
|
||||||
void initeditIndex();
|
|
||||||
void oriCur2Edit();//载入原有曲线
|
|
||||||
void drawEditLine(QPainter *painter);//绘制编辑曲线
|
|
||||||
void genEditLine();//生成编辑曲线
|
|
||||||
void changeEditStrValue(int temp);//单回合编辑中更新起始编辑点
|
|
||||||
void sortEdit();//顺序
|
|
||||||
bool saveEdit(int Smooth);//保存编辑
|
|
||||||
void overEdit();//结束编辑
|
|
||||||
|
|
||||||
void AngAdjWin();
|
|
||||||
void smoothWin();
|
|
||||||
|
|
||||||
bool isIneditRange(int);
|
|
||||||
private:
|
|
||||||
bool press_noRelease_mode; //点下未抬起状态
|
|
||||||
int press_noRelease_point; //点下未抬起状态下鼠标位置
|
|
||||||
|
|
||||||
float *m_values;
|
|
||||||
int m_count;
|
|
||||||
bool isInit;
|
|
||||||
|
|
||||||
float m_width;
|
|
||||||
float m_height;
|
|
||||||
QPoint lastPos;
|
|
||||||
QPoint frontPos;
|
|
||||||
QList<float> underBarHeight;
|
|
||||||
|
|
||||||
editEnd *msgBox2;
|
|
||||||
bool editLock;
|
|
||||||
bool ifContinue;//继续编辑标
|
|
||||||
int pressPoint, releasePoint;//记录修改上下界
|
|
||||||
int pressEdit,releaseEdit,curEdit,tempCurEdit; //编辑范围
|
|
||||||
int lastEditPos,editIndexNum;
|
|
||||||
int tempPEdit,tempREdit;//备份
|
|
||||||
float *editValue, *tempEditValue;//编辑值
|
|
||||||
int *editIndex;//有编辑过的index
|
|
||||||
|
|
||||||
int editStrValue, onceEditNum;//编辑起始位置,单次编辑量
|
|
||||||
int *onceEditIndex;//单次修改index记录
|
|
||||||
|
|
||||||
bool hasSelect;//选中区域标识
|
|
||||||
int whichMode;
|
|
||||||
bool EditMode;
|
|
||||||
|
|
||||||
SmoothTool *sTool;
|
|
||||||
AngleAdjTool *angTool;
|
|
||||||
|
|
||||||
float mouseDrawDepth, mouseDrawValue;//实时记录鼠标所在深度及数值
|
|
||||||
|
|
||||||
QPoint tishiEdit;
|
|
||||||
float tishiEditTime;
|
|
||||||
public:
|
|
||||||
QString fileName, curveName;
|
|
||||||
|
|
||||||
int PageSize,CurrentPos,userPos;
|
|
||||||
|
|
||||||
float userCurrentPos;
|
|
||||||
float userCurrentValue;
|
|
||||||
|
|
||||||
QRect rthy,rthy1,rthyt;
|
|
||||||
float factor;
|
|
||||||
float m_Xmin,m_Xmax;
|
|
||||||
float sdep,edep,rlev;
|
|
||||||
public:
|
|
||||||
void button_editIfBegin();
|
|
||||||
void button_smoothWin();
|
|
||||||
void button_AngAdjWin();
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // DRAWCURVEVIEW_H
|
|
||||||
|
|
@ -1,555 +0,0 @@
|
||||||
#include "ShowCurve.h"
|
|
||||||
#include "ui_ShowCurve.h"
|
|
||||||
//#include "DrawAPicture.h"
|
|
||||||
#include <QDebug>
|
|
||||||
#include <qtimer.h>
|
|
||||||
#include <QPainter>
|
|
||||||
#include <QComboBox>
|
|
||||||
#include <QTextCodec>
|
|
||||||
#include <QMessageBox>
|
|
||||||
#include <QResizeEvent>
|
|
||||||
#include <qtextbrowser.h>
|
|
||||||
#include <QPropertyAnimation>
|
|
||||||
#include "geometryutils.h"
|
|
||||||
#include "CallManage.h"
|
|
||||||
|
|
||||||
#define R2LTIPS "请拖动数据表格纵向滑块即可完成深度初定位."
|
|
||||||
#define EDITMODETIPS "正处于编辑模式单击右键以完成编辑."
|
|
||||||
|
|
||||||
ShowCurve::ShowCurve(QWidget *parent) :
|
|
||||||
QWidget(parent),
|
|
||||||
m_pUI(new Ui::ShowCurve),vmax(-9999),vmin(-9999),
|
|
||||||
mouseDepth(0),
|
|
||||||
mouseValue(0),
|
|
||||||
getBar(false),
|
|
||||||
locked(true),
|
|
||||||
hasTipsWidth(false)
|
|
||||||
{
|
|
||||||
val=NULL;
|
|
||||||
m_pUI->setupUi(this);
|
|
||||||
int w = width();
|
|
||||||
int h = height();
|
|
||||||
m_timer = new QTimer();
|
|
||||||
|
|
||||||
if(NULL != parent)
|
|
||||||
{
|
|
||||||
parent->setFixedSize(w,h);
|
|
||||||
}
|
|
||||||
|
|
||||||
thisParent = parent;
|
|
||||||
m_view = new DrawCurveView();
|
|
||||||
|
|
||||||
m_pUI->pushButton->setEnabled(false);
|
|
||||||
m_pUI->pushButton_2->setEnabled(false);
|
|
||||||
m_pUI->pushButton_3->setEnabled(false);
|
|
||||||
|
|
||||||
|
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_ValueChange(int, float)), this, SLOT(linkVerDeptSliderValueChange(int, float)));
|
|
||||||
connect(m_pUI->verticalSlider,SIGNAL(valueChanged(int)),this,SLOT(onVerDeptSliderValueChange(int)));
|
|
||||||
connect(m_view, SIGNAL(verticalSliderUP()), this, SLOT(SliderUP_SLOT()));
|
|
||||||
connect(m_view, SIGNAL(verticalSliderDOWN()), this, SLOT(SliderDOWN_SLOT()));
|
|
||||||
connect(m_view, SIGNAL(editModeTips()), this, SLOT(editModeTips_SLOT()));
|
|
||||||
|
|
||||||
connect(m_pUI->deptEdit->lineEdit_Depth, SIGNAL(textChanged( QString )),this,SLOT(slotChangeDepth(QString)));
|
|
||||||
connect(m_pUI->pushButtonScale, SIGNAL(clicked()), this, SLOT(slotChangeScale()));
|
|
||||||
connect(m_pUI->pushButtonStretch, SIGNAL(clicked()), this, SLOT(slotStretch()));
|
|
||||||
connect(m_pUI->pushButtonCompres, SIGNAL(clicked()), this, SLOT(slotCompres()));
|
|
||||||
|
|
||||||
connect(m_pUI->pushButton, SIGNAL(clicked()), this, SLOT(editSig_SLOT()));
|
|
||||||
connect(m_pUI->pushButton_2, SIGNAL(clicked()), this, SLOT(smoothSig_SLOT()));
|
|
||||||
connect(m_pUI->pushButton_3, SIGNAL(clicked()), this, SLOT(angSig_SLOT()));
|
|
||||||
connect(m_view, SIGNAL(enableEditButtons()), this, SLOT(editButtonsCon_SLOT()));
|
|
||||||
connect(m_view, SIGNAL(unableEditButtons()), this, SLOT(unEditButtonsCon_SLOT()));
|
|
||||||
|
|
||||||
//测试
|
|
||||||
// connect(m_pUI->pushButton_4, SIGNAL(clicked()), this, SLOT(testButton_SLOT()));
|
|
||||||
|
|
||||||
QPixmap pushButton_5Pixmap; pushButton_5Pixmap.load(::GetImagePath() + "/UIMake/R2L.png");
|
|
||||||
m_pUI->pushButton_5->setFixedSize(pushButton_5Pixmap.width(), pushButton_5Pixmap.height());
|
|
||||||
m_pUI->pushButton_5->setIcon(pushButton_5Pixmap);
|
|
||||||
m_pUI->pushButton_5->setIconSize(QSize(pushButton_5Pixmap.width(), pushButton_5Pixmap.height()));
|
|
||||||
//m_pUI->pushButton_5->setFlat(true);
|
|
||||||
connect(m_pUI->pushButton_5, SIGNAL(clicked()), this, SLOT(R2LButton_SLOT()));
|
|
||||||
connect(m_view, SIGNAL(R2L()), this, SLOT(R2LMouse_SLOT()));
|
|
||||||
connect(m_pUI->lineEdit_Value, SIGNAL(returnPressed()), this, SLOT(R2LButton_SLOT()));
|
|
||||||
m_pUI->lineEdit_Value->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
|
|
||||||
QPixmap pushButton_6Pixmap;
|
|
||||||
pushButton_6Pixmap.load(::GetImagePath() + "/UIMake/L2RLock.png");
|
|
||||||
m_pUI->pushButton_6->setFixedSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height());
|
|
||||||
m_pUI->pushButton_6->setIcon(pushButton_6Pixmap);
|
|
||||||
m_pUI->pushButton_6->setIconSize(QSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height()));
|
|
||||||
//m_pUI->pushButton_6->setFlat(true);
|
|
||||||
connect(m_pUI->pushButton_6, SIGNAL(clicked()), this, SLOT(lockChange_SLOT()));
|
|
||||||
|
|
||||||
|
|
||||||
QPixmap sizeButtonPixmap;
|
|
||||||
sizeButtonPixmap.load(::GetImagePath() + "/UIMake/UIButtonBig_o.png");
|
|
||||||
m_pUI->pushButtonStretch->setFixedSize(sizeButtonPixmap.width(), sizeButtonPixmap.height());
|
|
||||||
m_pUI->pushButtonStretch->setIcon(sizeButtonPixmap);
|
|
||||||
m_pUI->pushButtonStretch->setIconSize(QSize(sizeButtonPixmap.width(), sizeButtonPixmap.height()));
|
|
||||||
//m_pUI->pushButtonStretch->setStyleSheet("QPushButton:hover{background-color: rgb(254,164,134);}");
|
|
||||||
//m_pUI->pushButtonStretch->setFlat(true);
|
|
||||||
sizeButtonPixmap.load(::GetImagePath() + "/UIMake/UIButtonSmall_o.png");
|
|
||||||
m_pUI->pushButtonCompres->setFixedSize(sizeButtonPixmap.width(), sizeButtonPixmap.height());
|
|
||||||
m_pUI->pushButtonCompres->setIcon(sizeButtonPixmap);
|
|
||||||
m_pUI->pushButtonCompres->setIconSize(QSize(sizeButtonPixmap.width(), sizeButtonPixmap.height()));
|
|
||||||
//m_pUI->pushButtonCompres->setFlat(true);
|
|
||||||
|
|
||||||
tipsHeight = m_pUI->textBrowser->height();
|
|
||||||
//m_pUI->textBrowser->verticalScrollBar()->setVisible(false);
|
|
||||||
//m_pUI->textBrowser->horizontalScrollBar()->setVisible(false);
|
|
||||||
QPalette pa;
|
|
||||||
pa.setColor(QPalette::WindowText, QColor(120,120,120));
|
|
||||||
m_pUI->textBrowser->setPalette(pa);
|
|
||||||
}
|
|
||||||
void ShowCurve::testButton_SLOT()
|
|
||||||
{
|
|
||||||
|
|
||||||
// DrawAPicture *t = new DrawAPicture();
|
|
||||||
// t->show();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::init()
|
|
||||||
{
|
|
||||||
CLogIO *logio=new CLogIO();
|
|
||||||
logio->Open(FileName.toStdString().c_str(),CSlfIO::modeRead);
|
|
||||||
index=logio->OpenCurve(CurveName.toStdString().c_str());
|
|
||||||
if(index<0) {
|
|
||||||
delete logio;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
logio->GetCurveInfo(index,&curveinfo);
|
|
||||||
sdep=curveinfo.StartDepth;
|
|
||||||
edep=curveinfo.EndDepth;
|
|
||||||
rlev=curveinfo.DepLevel;
|
|
||||||
m_view->sdep = sdep;
|
|
||||||
m_view->edep = edep;
|
|
||||||
m_view->rlev = rlev;
|
|
||||||
m_view->userPos = 0;
|
|
||||||
m_view->fileName = FileName;
|
|
||||||
m_view->curveName = CurveName;
|
|
||||||
curDepth=sdep+(edep-sdep)/2.;
|
|
||||||
|
|
||||||
count=(curveinfo.EndDepth-curveinfo.StartDepth)/curveinfo.DepLevel+1.5;
|
|
||||||
val=new float[count];
|
|
||||||
logio->ReadCurve(index,curveinfo.StartDepth,count,&val[0]);
|
|
||||||
logio->CloseCurve(index);
|
|
||||||
delete logio;
|
|
||||||
|
|
||||||
if(vmax==-9999 && vmin==-9999)
|
|
||||||
if(!getValueRangeFromIni()){
|
|
||||||
vmax=vmin=val[0];
|
|
||||||
for(int i=1;i<count;i++)
|
|
||||||
{
|
|
||||||
if(vmax<val[i])vmax=val[i];
|
|
||||||
if(vmin>val[i])vmin=val[i];
|
|
||||||
}
|
|
||||||
m_view->m_Xmax=vmax,m_view->m_Xmin=vmin;
|
|
||||||
|
|
||||||
m_pUI->lineEdit_Xmax->setText(QString::number(vmax));
|
|
||||||
m_pUI->lineEdit_Xmax->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
m_pUI->lineEdit_Xmin->setText(QString::number(vmin));
|
|
||||||
m_pUI->lineEdit_Xmin->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
}
|
|
||||||
|
|
||||||
m_view->setValues(val);
|
|
||||||
m_view->factor=2;
|
|
||||||
initVerMaxRange = 200;
|
|
||||||
m_view->PageSize = int(count / initVerMaxRange + 100);
|
|
||||||
if(m_view->PageSize < 500) m_view->PageSize=500;
|
|
||||||
//m_view.PageSize=(int)(200./curveinfo.DepLevel+0.5);
|
|
||||||
//for small rlev
|
|
||||||
//if(curveinfo.DepLevel<0.005)m_view.PageSize/=100;
|
|
||||||
//else if(curveinfo.DepLevel<0.05)m_view.PageSize/=10;
|
|
||||||
|
|
||||||
|
|
||||||
QString title= QString( curveinfo.Name)+QString::fromUtf8("曲线预览");
|
|
||||||
m_pUI->label_WfName->setText(title);
|
|
||||||
m_pUI->label_StartDepth->setText(QString::number(sdep));
|
|
||||||
m_pUI->label_EndDepth->setText(QString::number(edep));
|
|
||||||
|
|
||||||
m_pUI->deptEdit->lineEdit_Depth->setText(QString::number(curDepth));
|
|
||||||
m_pUI->deptEdit->lineEdit_Depth->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
|
|
||||||
QPalette pal;
|
|
||||||
m_pUI->widgetPlot->setStyleSheet("background:lightgray");
|
|
||||||
m_pUI->widgetPlot->setPalette(pal);
|
|
||||||
m_view->setParent(m_pUI->widgetPlot);
|
|
||||||
m_view->setCount(count);
|
|
||||||
m_pUI->verticalSlider->setRange(0, initVerMaxRange);
|
|
||||||
m_pUI->verticalSlider->setValue(initVerMaxRange / 2);
|
|
||||||
}
|
|
||||||
|
|
||||||
bool ShowCurve::getValueRangeFromIni()
|
|
||||||
{
|
|
||||||
QString curveFamilyFilePath = ::GetConfPath() + "CurveFamily.ini";
|
|
||||||
QFile curveFamilyFile(curveFamilyFilePath);
|
|
||||||
if(!curveFamilyFile.open(QIODevice::ReadOnly | QIODevice::Text)) return false;
|
|
||||||
|
|
||||||
bool finished = false;
|
|
||||||
while(!curveFamilyFile.atEnd())
|
|
||||||
{
|
|
||||||
QByteArray line = curveFamilyFile.readLine();
|
|
||||||
QString str(line);
|
|
||||||
QStringList strList = str.split("=");
|
|
||||||
if(strList[0] == CurveName)
|
|
||||||
{
|
|
||||||
strList = str.split(",");
|
|
||||||
float minValue = strList[1].toFloat();
|
|
||||||
float maxValue = strList[2].toFloat();
|
|
||||||
if(minValue < -9999 || minValue > 9999) return false;
|
|
||||||
if(maxValue < -9999 || maxValue > 9999) return false;
|
|
||||||
if(maxValue <= minValue) return false;
|
|
||||||
m_view->m_Xmax=maxValue,m_view->m_Xmin=minValue;
|
|
||||||
|
|
||||||
m_pUI->lineEdit_Xmax->setText(QString::number(maxValue));
|
|
||||||
m_pUI->lineEdit_Xmax->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
m_pUI->lineEdit_Xmin->setText(QString::number(minValue));
|
|
||||||
m_pUI->lineEdit_Xmin->setValidator(new QDoubleValidator(-9999999,9999999,6,this));
|
|
||||||
|
|
||||||
finished = true;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
curveFamilyFile.close();
|
|
||||||
|
|
||||||
return finished;
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::editSig_SLOT()
|
|
||||||
{
|
|
||||||
m_view->button_editIfBegin();
|
|
||||||
}
|
|
||||||
void ShowCurve::smoothSig_SLOT()
|
|
||||||
{
|
|
||||||
m_view->button_smoothWin();
|
|
||||||
}
|
|
||||||
void ShowCurve::angSig_SLOT()
|
|
||||||
{
|
|
||||||
m_view->button_AngAdjWin();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::editModeTips_SLOT()
|
|
||||||
{
|
|
||||||
if(!hasTipsWidth){
|
|
||||||
tipsWidth = m_pUI->textBrowser->width();
|
|
||||||
hasTipsWidth = true;
|
|
||||||
}
|
|
||||||
tipsText = QString::fromUtf8(EDITMODETIPS);
|
|
||||||
m_pUI->textBrowser->setText(tipsText);
|
|
||||||
m_pUI->textBrowser->setGeometry(QRect( m_pUI->textBrowser->x(),
|
|
||||||
m_pUI->textBrowser->y(),
|
|
||||||
tipsWidth,
|
|
||||||
m_pUI->textBrowser->height()));
|
|
||||||
|
|
||||||
connect(m_timer, SIGNAL(timeout()), SLOT(promptDisplay()));
|
|
||||||
m_timer->setInterval(1000);
|
|
||||||
m_timer->start();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::slotChangeDepth(const QString &text)
|
|
||||||
{
|
|
||||||
if(text.toFloat() < sdep || text.toFloat() > edep)
|
|
||||||
{
|
|
||||||
// m_pUI->lineEdit_Depth->setText(QString::number(curDepth));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
curDepth = text.toFloat();
|
|
||||||
if(curveinfo.EndDepth == curveinfo.StartDepth) {
|
|
||||||
m_view->CurrentPos = 0;
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
m_view->CurrentPos = (curDepth - curveinfo.StartDepth) / (curveinfo.EndDepth - curveinfo.StartDepth) * count;
|
|
||||||
}
|
|
||||||
|
|
||||||
//m_pUI->lineEdit_Value->setText(QString::number(curDepth));
|
|
||||||
m_view->update();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::resizeEvent(QResizeEvent *resize)
|
|
||||||
{
|
|
||||||
QSize orgsize=this->size();
|
|
||||||
QWidget::resizeEvent(resize);
|
|
||||||
|
|
||||||
if(resize->size().isValid())
|
|
||||||
{
|
|
||||||
QSize changeSize=resize->size();
|
|
||||||
int width=changeSize.width()-orgsize.width();
|
|
||||||
int height= changeSize.height()-orgsize.height();
|
|
||||||
|
|
||||||
m_view->resize(changeSize.width()-150,changeSize.height()-100);
|
|
||||||
m_view->initView();
|
|
||||||
m_view->update();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::onVerDeptSliderValueChange(int value)
|
|
||||||
{
|
|
||||||
curDepth = edep - (edep-sdep) * value / initVerMaxRange;
|
|
||||||
m_pUI->deptEdit->lineEdit_Depth->setText(QString::number(curDepth));
|
|
||||||
m_view->update();
|
|
||||||
|
|
||||||
curDepRange();
|
|
||||||
|
|
||||||
//setCurveTableForce(curDepth);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::SliderUP_SLOT()
|
|
||||||
{
|
|
||||||
m_pUI->verticalSlider->setValue(m_pUI->verticalSlider->value() + 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::SliderDOWN_SLOT()
|
|
||||||
{
|
|
||||||
m_pUI->verticalSlider->setValue(m_pUI->verticalSlider->value() - 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::mouseMkChange(float depth, float value){
|
|
||||||
mouseDepth = depth;
|
|
||||||
mouseValue = value;
|
|
||||||
//m_pUI->lineEdit_Value->setText(QString::number(depth));
|
|
||||||
//m_pUI->lineEdit_curValue->setText(QString::number(value));
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::lineEdit_curValue_Change(float v){
|
|
||||||
//m_pUI->lineEdit_curValue->setText(QString::number(v));
|
|
||||||
}
|
|
||||||
|
|
||||||
//联动
|
|
||||||
void ShowCurve::linkVerDeptSliderValueChange(int value, float tipValue)
|
|
||||||
{
|
|
||||||
if(rlev <= 0 || edep == sdep || locked == false)return;
|
|
||||||
|
|
||||||
m_pUI->deptEdit->lineEdit_Depth->setText(QString::number(tipValue));
|
|
||||||
m_pUI->lineEdit_Value->setText(QString::number(tipValue));
|
|
||||||
|
|
||||||
int pageNo = (edep - tipValue) / (edep-sdep) * initVerMaxRange + m_view->PageSize / 2 * rlev / ((edep-sdep)/initVerMaxRange);
|
|
||||||
if(pageNo > initVerMaxRange) pageNo = initVerMaxRange;
|
|
||||||
|
|
||||||
int curCount = (tipValue - sdep) / rlev + 0.5;
|
|
||||||
//m_pUI->lineEdit_curValue->setText(QString::number(val[curCount]));
|
|
||||||
|
|
||||||
m_pUI->verticalSlider->setValue(pageNo);
|
|
||||||
onVerDeptSliderValueChange(pageNo);
|
|
||||||
|
|
||||||
m_view->userCurrentPos = tipValue;
|
|
||||||
|
|
||||||
m_view->update();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::setTableBro(QScrollBar *p)
|
|
||||||
{
|
|
||||||
getBar = true;
|
|
||||||
tableBro = p;
|
|
||||||
}
|
|
||||||
void ShowCurve::setCurveTable(QTableWidget *t)
|
|
||||||
{
|
|
||||||
curveTable = t;
|
|
||||||
}
|
|
||||||
|
|
||||||
//改变刻度按钮槽
|
|
||||||
void ShowCurve::slotChangeScale()
|
|
||||||
{
|
|
||||||
m_view->m_Xmin=m_pUI->lineEdit_Xmin->text().toFloat();
|
|
||||||
m_view->m_Xmax=m_pUI->lineEdit_Xmax->text().toFloat();
|
|
||||||
m_view->update();
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::slotStretch()//深度拉伸
|
|
||||||
{
|
|
||||||
initVerMaxRange *= 1.5;
|
|
||||||
if(initVerMaxRange == 1)initVerMaxRange=2;
|
|
||||||
m_pUI->verticalSlider->setRange(0, initVerMaxRange);
|
|
||||||
|
|
||||||
if(!m_pUI->pushButtonCompres->isEnabled())
|
|
||||||
m_pUI->pushButtonCompres->setEnabled(true);
|
|
||||||
|
|
||||||
m_view->PageSize/=1.5;
|
|
||||||
if(m_view->PageSize < 50)
|
|
||||||
m_pUI->pushButtonStretch->setEnabled(false);
|
|
||||||
|
|
||||||
m_view->update();
|
|
||||||
|
|
||||||
curDepRange();
|
|
||||||
}
|
|
||||||
void ShowCurve::slotCompres()//深度压缩
|
|
||||||
{
|
|
||||||
initVerMaxRange /= 1.5;
|
|
||||||
|
|
||||||
if(initVerMaxRange / 1.5 <= 1)
|
|
||||||
m_pUI->pushButtonCompres->setEnabled(false);
|
|
||||||
|
|
||||||
m_pUI->verticalSlider->setRange(0, initVerMaxRange);
|
|
||||||
|
|
||||||
if(!m_pUI->pushButtonStretch->isEnabled())
|
|
||||||
m_pUI->pushButtonStretch->setEnabled(true);
|
|
||||||
|
|
||||||
m_view->PageSize*=1.5;
|
|
||||||
m_view->update();
|
|
||||||
|
|
||||||
curDepRange();
|
|
||||||
}
|
|
||||||
|
|
||||||
//改变绘制窗口的深度显示
|
|
||||||
void ShowCurve::curDepRange()
|
|
||||||
{
|
|
||||||
float cDR_value = m_pUI->verticalSlider->value();
|
|
||||||
float cDR_startDepth = edep - (edep-sdep) * cDR_value / initVerMaxRange;
|
|
||||||
float cDR_endDepth = cDR_startDepth + m_view->PageSize * rlev;
|
|
||||||
|
|
||||||
m_pUI->label_StartDepth->setText(QString::number(cDR_startDepth));
|
|
||||||
m_pUI->label_EndDepth->setText(QString::number(cDR_endDepth));
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::showEvent(QShowEvent *sEvent)
|
|
||||||
{
|
|
||||||
QWidget::showEvent(sEvent);
|
|
||||||
|
|
||||||
QRect rec=m_pUI->widgetPlot->geometry();
|
|
||||||
qDebug()<<"value:"<<rec;
|
|
||||||
int w=rec.width();
|
|
||||||
int h=rec.height();
|
|
||||||
|
|
||||||
m_view->setGeometry(0,0,w,h);
|
|
||||||
|
|
||||||
m_view->initView();
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
ShowCurve::~ShowCurve()
|
|
||||||
{
|
|
||||||
delete m_pUI;
|
|
||||||
if(val)delete []val;
|
|
||||||
delete m_view;
|
|
||||||
delete m_timer;
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::editButtonsCon_SLOT()
|
|
||||||
{
|
|
||||||
m_pUI->pushButton->setEnabled(true);
|
|
||||||
m_pUI->pushButton_2->setEnabled(true);
|
|
||||||
m_pUI->pushButton_3->setEnabled(true);
|
|
||||||
}
|
|
||||||
void ShowCurve::unEditButtonsCon_SLOT()
|
|
||||||
{
|
|
||||||
m_pUI->pushButton->setEnabled(false);
|
|
||||||
m_pUI->pushButton_2->setEnabled(false);
|
|
||||||
m_pUI->pushButton_3->setEnabled(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::R2LButton_SLOT()
|
|
||||||
{
|
|
||||||
if(!getBar){
|
|
||||||
if(!hasTipsWidth){
|
|
||||||
tipsWidth = m_pUI->textBrowser->width();
|
|
||||||
hasTipsWidth = true;
|
|
||||||
}
|
|
||||||
tipsText = QString::fromUtf8(R2LTIPS);
|
|
||||||
m_pUI->textBrowser->setText(tipsText);
|
|
||||||
m_pUI->textBrowser->setGeometry(QRect( m_pUI->textBrowser->x(),
|
|
||||||
m_pUI->textBrowser->y(),
|
|
||||||
tipsWidth,
|
|
||||||
m_pUI->textBrowser->height()));
|
|
||||||
|
|
||||||
connect(m_timer, SIGNAL(timeout()), SLOT(promptDisplay()));
|
|
||||||
m_timer->setInterval(1000);
|
|
||||||
m_timer->start();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
//以输入框深度信息
|
|
||||||
float R2L_depthValue = m_pUI->lineEdit_Value->text().toFloat();
|
|
||||||
m_view->userCurrentPos = R2L_depthValue;
|
|
||||||
|
|
||||||
int pageNo = (edep - R2L_depthValue) / (edep-sdep) * initVerMaxRange + m_view->PageSize / 2 * rlev / ((edep-sdep)/initVerMaxRange);
|
|
||||||
if(pageNo > initVerMaxRange) pageNo = initVerMaxRange;
|
|
||||||
m_pUI->verticalSlider->setValue(pageNo);
|
|
||||||
|
|
||||||
int tv = tableBro->maximum();
|
|
||||||
float oneValue = (edep - sdep) / tv;
|
|
||||||
int bv = (R2L_depthValue - sdep) / oneValue;
|
|
||||||
tableBro->setValue(bv);
|
|
||||||
|
|
||||||
setCurveTableForce(R2L_depthValue);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::R2LMouse_SLOT()
|
|
||||||
{
|
|
||||||
if(!getBar) return;
|
|
||||||
|
|
||||||
//以鼠标位置深度信息
|
|
||||||
m_view->userCurrentPos = mouseDepth;
|
|
||||||
|
|
||||||
m_pUI->lineEdit_Value->setText(QString::number(mouseDepth));
|
|
||||||
//m_pUI->lineEdit_curValue->setText(QString::number(mouseValue));
|
|
||||||
|
|
||||||
int tv = tableBro->maximum();
|
|
||||||
float oneValue = (edep - sdep) / tv;
|
|
||||||
int bv = (mouseDepth - sdep) / oneValue;
|
|
||||||
tableBro->setValue(bv);
|
|
||||||
|
|
||||||
setCurveTableForce(mouseDepth);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::promptDisplay()
|
|
||||||
{
|
|
||||||
m_timer->stop();
|
|
||||||
|
|
||||||
//m_pUI->textBrowser->setText(tipsText);
|
|
||||||
//m_pUI->textBrowser->windowOpacity
|
|
||||||
QPropertyAnimation *tipsAnimation = new QPropertyAnimation(m_pUI->textBrowser, "geometry");
|
|
||||||
tipsAnimation->setDuration(2000);
|
|
||||||
tipsAnimation->setStartValue(QRect( m_pUI->textBrowser->x(),
|
|
||||||
m_pUI->textBrowser->y(),
|
|
||||||
tipsWidth,
|
|
||||||
m_pUI->textBrowser->height()
|
|
||||||
));
|
|
||||||
tipsAnimation->setEndValue(QRect( m_pUI->textBrowser->x(),
|
|
||||||
m_pUI->textBrowser->y(),
|
|
||||||
0,
|
|
||||||
m_pUI->textBrowser->height()
|
|
||||||
));
|
|
||||||
|
|
||||||
tipsAnimation->start();
|
|
||||||
connect(tipsAnimation, SIGNAL(finished()), this, SLOT(clearTips_SLOT()));
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::clearTips_SLOT()
|
|
||||||
{
|
|
||||||
m_pUI->textBrowser->setText("");
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::setCurveTableForce(float dep)
|
|
||||||
{
|
|
||||||
float tv = tableBro->maximum();
|
|
||||||
float oneValue = (edep - sdep) / tv;
|
|
||||||
int bv = (dep - sdep) / oneValue;
|
|
||||||
|
|
||||||
float SCTF_r = bv / tv;
|
|
||||||
|
|
||||||
int SCTF_pos = (curveTable->rowCount()+1) * SCTF_r;
|
|
||||||
|
|
||||||
qDebug() << "setCurveTableForce" << QString::number(SCTF_pos);
|
|
||||||
curveTable->selectRow(SCTF_pos);
|
|
||||||
}
|
|
||||||
|
|
||||||
void ShowCurve::lockChange_SLOT()
|
|
||||||
{
|
|
||||||
locked = !locked;
|
|
||||||
if(locked){
|
|
||||||
QPixmap pushButton_6Pixmap;
|
|
||||||
pushButton_6Pixmap.load(::GetImagePath() + "/UIMake/L2RLock.png");
|
|
||||||
m_pUI->pushButton_6->setFixedSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height());
|
|
||||||
m_pUI->pushButton_6->setIcon(pushButton_6Pixmap);
|
|
||||||
m_pUI->pushButton_6->setIconSize(QSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height()));
|
|
||||||
}
|
|
||||||
else{
|
|
||||||
QPixmap pushButton_6Pixmap;
|
|
||||||
pushButton_6Pixmap.load(::GetImagePath() + "/UIMake/L2RUnlock.png");
|
|
||||||
m_pUI->pushButton_6->setFixedSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height());
|
|
||||||
m_pUI->pushButton_6->setIcon(pushButton_6Pixmap);
|
|
||||||
m_pUI->pushButton_6->setIconSize(QSize(pushButton_6Pixmap.width(), pushButton_6Pixmap.height()));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,93 +0,0 @@
|
||||||
#ifndef WIDGET_H1
|
|
||||||
#define WIDGET_H1
|
|
||||||
|
|
||||||
#include <QDir>
|
|
||||||
#include <QWidget>
|
|
||||||
#include <QFileInfo>
|
|
||||||
#include <QScrollBar>
|
|
||||||
#include <qtablewidget.h>
|
|
||||||
#include <QTableWidgetItem>
|
|
||||||
//#include <windows.h>
|
|
||||||
#include "MemRdWt.h"
|
|
||||||
#include "DrawCurveView.h"
|
|
||||||
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
|
|
||||||
namespace Ui {
|
|
||||||
class ShowCurve;
|
|
||||||
}
|
|
||||||
|
|
||||||
class ShowCurve : public QWidget
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
|
||||||
explicit ShowCurve(QWidget *parent = 0);
|
|
||||||
~ShowCurve();
|
|
||||||
Slf_CURVE curveinfo;
|
|
||||||
float *val;
|
|
||||||
DWORD count;
|
|
||||||
float sdep,edep,rlev,stime,etime,curTime,curDepth;
|
|
||||||
float vmax,vmin;
|
|
||||||
DrawCurveView *m_view;
|
|
||||||
//void readcurve();
|
|
||||||
void init();
|
|
||||||
QString FileName,CurveName;
|
|
||||||
int index;
|
|
||||||
|
|
||||||
int initVerMaxRange;
|
|
||||||
|
|
||||||
void mouseMkChange(float depth, float value);
|
|
||||||
|
|
||||||
void lineEdit_curValue_Change(float);
|
|
||||||
|
|
||||||
void setTableBro(QScrollBar *p);
|
|
||||||
void setCurveTable(QTableWidget *t);
|
|
||||||
protected:
|
|
||||||
//implement class QWidget
|
|
||||||
virtual void showEvent(QShowEvent *sEvent);
|
|
||||||
virtual void resizeEvent(QResizeEvent *resize);
|
|
||||||
|
|
||||||
public slots:
|
|
||||||
void onVerDeptSliderValueChange(int value);
|
|
||||||
void SliderUP_SLOT();
|
|
||||||
void SliderDOWN_SLOT();
|
|
||||||
void linkVerDeptSliderValueChange(int value,float tipValue);
|
|
||||||
void slotChangeDepth(const QString &text);
|
|
||||||
void slotChangeScale();
|
|
||||||
void slotStretch();
|
|
||||||
void slotCompres();
|
|
||||||
|
|
||||||
void editSig_SLOT();
|
|
||||||
void smoothSig_SLOT();
|
|
||||||
void angSig_SLOT();
|
|
||||||
void editButtonsCon_SLOT();
|
|
||||||
void unEditButtonsCon_SLOT();
|
|
||||||
void R2LButton_SLOT();
|
|
||||||
void R2LMouse_SLOT();
|
|
||||||
private:
|
|
||||||
bool getBar;
|
|
||||||
bool locked;
|
|
||||||
float mouseDepth, mouseValue;
|
|
||||||
QScrollBar *tableBro;
|
|
||||||
QTableWidget *curveTable;
|
|
||||||
QWidget* thisParent;
|
|
||||||
Ui::ShowCurve *m_pUI;
|
|
||||||
float tipsWidth, tipsHeight;
|
|
||||||
bool hasTipsWidth;
|
|
||||||
QTimer *m_timer;
|
|
||||||
QString tipsText;
|
|
||||||
|
|
||||||
void curDepRange();
|
|
||||||
void setCurveTableForce(float dep);
|
|
||||||
bool getValueRangeFromIni();
|
|
||||||
|
|
||||||
private slots:
|
|
||||||
void testButton_SLOT();
|
|
||||||
void lockChange_SLOT();
|
|
||||||
void editModeTips_SLOT();
|
|
||||||
void promptDisplay();
|
|
||||||
void clearTips_SLOT();
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
@ -1,580 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<ui version="4.0">
|
|
||||||
<class>ShowCurve</class>
|
|
||||||
<widget class="QWidget" name="ShowCurve">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>1000</width>
|
|
||||||
<height>800</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>400</width>
|
|
||||||
<height>571</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>16777215</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>曲线预览</string>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
|
||||||
<item row="0" column="0" colspan="3">
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
|
||||||
<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="label_WfName">
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线:</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>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item row="1" column="2">
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_8" stretch="2,3,2">
|
|
||||||
<item>
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Xmin">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Ignored" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>16777215</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButtonScale">
|
|
||||||
<property name="text">
|
|
||||||
<string>改变刻度</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Xmax">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Ignored" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>1</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>16777215</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="baseSize">
|
|
||||||
<size>
|
|
||||||
<width>0</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="0" colspan="3">
|
|
||||||
<widget class="QWidget" name="widgetPlot" native="true">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>500</width>
|
|
||||||
<height>385</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="4">
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
|
||||||
<item>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="QSlider" name="verticalSlider">
|
|
||||||
<property name="minimum">
|
|
||||||
<number>0</number>
|
|
||||||
</property>
|
|
||||||
<property name="maximum">
|
|
||||||
<number>199</number>
|
|
||||||
</property>
|
|
||||||
<property name="singleStep">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<property name="pageStep">
|
|
||||||
<number>10</number>
|
|
||||||
</property>
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_3">
|
|
||||||
<item>
|
|
||||||
<spacer name="verticalSpacer_2">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>20</width>
|
|
||||||
<height>40</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_7">
|
|
||||||
<item>
|
|
||||||
<widget class="DeptLineEdit" name="deptEdit">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>55</width>
|
|
||||||
<height>200</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>55</width>
|
|
||||||
<height>200</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="frameShape">
|
|
||||||
<enum>QFrame::NoFrame</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="verticalSpacer">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>20</width>
|
|
||||||
<height>40</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton">
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>150</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>曲线绘制</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_2">
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>150</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>平滑处理</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_3">
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>150</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>基线校正</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="verticalSpacer_4">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>20</width>
|
|
||||||
<height>40</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="2">
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_12" stretch="2">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_3" stretch="2,4">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_11">
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_2">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>底深(m)</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_EndDepth">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>80</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>100</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>1000</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
|
||||||
</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>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="textBrowser">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="MinimumExpanding" vsizetype="Preferred">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item row="2" column="2">
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_10" stretch="2,4">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_9">
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>顶深(m)</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_StartDepth">
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="minimumSize">
|
|
||||||
<size>
|
|
||||||
<width>80</width>
|
|
||||||
<height>0</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>100</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>500</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<spacer name="horizontalSpacer_2">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QGroupBox" name="groupBox">
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true"/>
|
|
||||||
</property>
|
|
||||||
<property name="title">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
|
||||||
<property name="leftMargin">
|
|
||||||
<number>4</number>
|
|
||||||
</property>
|
|
||||||
<property name="topMargin">
|
|
||||||
<number>4</number>
|
|
||||||
</property>
|
|
||||||
<property name="rightMargin">
|
|
||||||
<number>4</number>
|
|
||||||
</property>
|
|
||||||
<property name="bottomMargin">
|
|
||||||
<number>4</number>
|
|
||||||
</property>
|
|
||||||
<item row="0" column="0">
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_4" stretch="2,2">
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButtonStretch">
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true">QPushButton:hover{background-color: rgba(0, 170, 255, 80);}
|
|
||||||
QPushButton{background-color: rgba(255, 255, 255, 0);}</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButtonCompres">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true">QPushButton:hover{background-color: rgba(0, 170, 255, 80);}QPushButton{background-color: rgba(255, 255, 255, 0);}</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="Line" name="line_2">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_6">
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>40</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true">QPushButton:hover{background-color: rgba(0, 170, 255, 80);}QPushButton{background-color: rgba(255, 255, 255, 0);}</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="Line" name="line_5">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Vertical</enum>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout_4">
|
|
||||||
<property name="spacing">
|
|
||||||
<number>1</number>
|
|
||||||
</property>
|
|
||||||
<item>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_6">
|
|
||||||
<item>
|
|
||||||
<widget class="QLabel" name="label_5">
|
|
||||||
<property name="text">
|
|
||||||
<string>深度定位(m)</string>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QLineEdit" name="lineEdit_Value">
|
|
||||||
<property name="enabled">
|
|
||||||
<bool>true</bool>
|
|
||||||
</property>
|
|
||||||
<property name="sizePolicy">
|
|
||||||
<sizepolicy hsizetype="Expanding" vsizetype="Fixed">
|
|
||||||
<horstretch>0</horstretch>
|
|
||||||
<verstretch>0</verstretch>
|
|
||||||
</sizepolicy>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="pushButton_5">
|
|
||||||
<property name="styleSheet">
|
|
||||||
<string notr="true">QPushButton:hover{background-color: rgba(0, 170, 255, 80);}QPushButton{background-color: rgba(255, 255, 255, 0);}</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<layoutdefault spacing="6" margin="11"/>
|
|
||||||
<customwidgets>
|
|
||||||
<customwidget>
|
|
||||||
<class>DeptLineEdit</class>
|
|
||||||
<extends>QGraphicsView</extends>
|
|
||||||
<header location="global">deptlineedit.h</header>
|
|
||||||
</customwidget>
|
|
||||||
</customwidgets>
|
|
||||||
<resources/>
|
|
||||||
<connections/>
|
|
||||||
</ui>
|
|
||||||
|
|
@ -21,8 +21,6 @@
|
||||||
//#include "ConsoleOutputWidget.h"
|
//#include "ConsoleOutputWidget.h"
|
||||||
|
|
||||||
#include "ui_WellLogTableDialogNew.h"
|
#include "ui_WellLogTableDialogNew.h"
|
||||||
#include "ShowCurve.h"
|
|
||||||
#include "CurvePropertyEdit.h"
|
|
||||||
#include "CallManage.h"
|
#include "CallManage.h"
|
||||||
#include "ObjectID.h"
|
#include "ObjectID.h"
|
||||||
//float保留4位小数
|
//float保留4位小数
|
||||||
|
|
@ -255,104 +253,6 @@ bool WellLogTableDialogNew::InitWellLog()
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
//swtichViewSize();
|
|
||||||
int Type=0;
|
|
||||||
//if(TypeName=="波列数据")Type=1;
|
|
||||||
|
|
||||||
QWidget* sPage=findChild<QWidget*>("statisticsPage");
|
|
||||||
QWidget* pPage=findChild<QWidget*>("protoprtyPage");
|
|
||||||
QWidget* cPage=findChild<QWidget*>("computePage");
|
|
||||||
QWidget* pvPage=findChild<QWidget*>("curvePreViewPage");
|
|
||||||
QTabWidget* tabWidget=findChild<QTabWidget*>("tabWidget");
|
|
||||||
if(NULL != sPage && NULL != pPage && NULL != cPage && NULL != pvPage)
|
|
||||||
{
|
|
||||||
if(NULL != tabWidget)
|
|
||||||
{
|
|
||||||
QScrollArea* sScrollArea=tabWidget->findChild<QScrollArea*>("sScrollArea");
|
|
||||||
QScrollArea* pScrollArea=tabWidget->findChild<QScrollArea*>("pScrollArea");
|
|
||||||
QScrollArea* cScrollArea=tabWidget->findChild<QScrollArea*>("cscrollArea");
|
|
||||||
QScrollArea* curveScrollArea=tabWidget->findChild<QScrollArea*>("curveScrollArea");
|
|
||||||
if(NULL != sScrollArea)
|
|
||||||
{
|
|
||||||
sScrollArea->setWidget(sPage);
|
|
||||||
}
|
|
||||||
|
|
||||||
if(NULL != pScrollArea)
|
|
||||||
{
|
|
||||||
pScrollArea->setWidget(pPage);
|
|
||||||
//属性
|
|
||||||
CCurvePropertyEditDlg *pDlg=new CCurvePropertyEditDlg(pPage, 0);
|
|
||||||
//connect(pDlg,SIGNAL(destroyed()),this,SLOT(slotCurvePropertyGc()));
|
|
||||||
pDlg->FileName=FileName;
|
|
||||||
pDlg->CurveName=CurveName;
|
|
||||||
pDlg->Type=Type;
|
|
||||||
//pDlg->init();
|
|
||||||
pDlg->show();
|
|
||||||
}
|
|
||||||
|
|
||||||
if(NULL != cScrollArea)
|
|
||||||
{
|
|
||||||
if(Type==0)cScrollArea->setWidget(cPage);
|
|
||||||
}
|
|
||||||
|
|
||||||
if(NULL != curveScrollArea)
|
|
||||||
{
|
|
||||||
curveScrollArea->setWidget(pvPage);
|
|
||||||
//曲线
|
|
||||||
ShowCurve *pDlg=new ShowCurve(m_pUI->curvePreViewPage);
|
|
||||||
pDlg->setObjectName("curveView");
|
|
||||||
pDlg->FileName=FileName;
|
|
||||||
pDlg->CurveName=CurveName;
|
|
||||||
pDlg->init();
|
|
||||||
pDlg->setCurveTable(m_pUI->tableWidget);
|
|
||||||
pDlg->show();
|
|
||||||
}
|
|
||||||
|
|
||||||
sPage->show();
|
|
||||||
pPage->show();
|
|
||||||
pvPage->show();
|
|
||||||
if(Type==0)
|
|
||||||
{
|
|
||||||
cPage->show();//whp change 2020.5.11 for 波列数据编辑和管理 波列曲线不计算
|
|
||||||
}
|
|
||||||
|
|
||||||
tabWidget->show();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// if(m_pWellLogs.size())
|
|
||||||
// {
|
|
||||||
// if ((m_pWellLogs[0]->GetTypeID()==GetClassID_WellLog()||
|
|
||||||
// m_pWellLogs[0]->GetTypeID()==GetClassID_WellTrajectory())&&m_pWellLogs[0]->m_ObjectType!=TABLE_OBJECT)//非多维数据
|
|
||||||
// {
|
|
||||||
// m_DataTyle=valid_NULL;
|
|
||||||
// m_gridData->initWellLogData(D_WellLogData ,m_pWellLogs);
|
|
||||||
// }
|
|
||||||
// else //多维数据
|
|
||||||
// if (m_pWellLogs[0]->GetTypeID()==GetClassID_WellLogWavefile())
|
|
||||||
// {
|
|
||||||
// m_DataTyle=valid_NULL;
|
|
||||||
// m_gridData->initMultWellLogData(D_MultWellLogData,m_pWellLogs);
|
|
||||||
// }
|
|
||||||
// else if (m_pWellLogs[0]->GetTypeID()==GetClassID_WellLogTDT())
|
|
||||||
// {
|
|
||||||
// m_DataTyle=valid_NULL;
|
|
||||||
// m_gridData->initTDTWellLogData(D_TDTWellLogData,m_pWellLogs);
|
|
||||||
// }
|
|
||||||
// else if (m_pWellLogs[0]->GetTypeID()==GetClassID_WellLogFMT())
|
|
||||||
// {
|
|
||||||
// m_DataTyle=valid_NULL;
|
|
||||||
// m_gridData->initFMTWellLogData(D_FMTWellLogData,m_pWellLogs);
|
|
||||||
// }
|
|
||||||
// else {
|
|
||||||
// m_gridData->addActonMenu(2);
|
|
||||||
|
|
||||||
// m_DataTyle=valid_NULL;
|
|
||||||
// //表格数据
|
|
||||||
// m_gridData->initTableWellLogData(D_TableWellLogData,m_pWellLogs);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -48,14 +48,11 @@ CONFIG(debug, debug|release){
|
||||||
|
|
||||||
FORMS += \
|
FORMS += \
|
||||||
AngleAdjTool.ui \
|
AngleAdjTool.ui \
|
||||||
CurvePropertyEdit.ui \
|
|
||||||
ShowCurve.ui \
|
|
||||||
SmoothTool.ui \
|
SmoothTool.ui \
|
||||||
WellDialog.ui \
|
WellDialog.ui \
|
||||||
WellLogProjectDialog.ui \
|
WellLogProjectDialog.ui \
|
||||||
WellLogRoundDialog.ui \
|
WellLogRoundDialog.ui \
|
||||||
WellLogTableDialogNew.ui \
|
WellLogTableDialogNew.ui
|
||||||
editEnd.ui
|
|
||||||
|
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
../../common/geometryutils.h \
|
../../common/geometryutils.h \
|
||||||
|
|
@ -73,23 +70,15 @@ HEADERS += \
|
||||||
../include/completertextedit.h \
|
../include/completertextedit.h \
|
||||||
../include/griddataadapter.h \
|
../include/griddataadapter.h \
|
||||||
AngleAdjTool.h \
|
AngleAdjTool.h \
|
||||||
CurvePropertyEdit.h \
|
|
||||||
DrawCurveView.h \
|
|
||||||
ShowCurve.h \
|
|
||||||
SmoothTool.h \
|
SmoothTool.h \
|
||||||
TipPop.h \
|
TipPop.h
|
||||||
deptlineedit.h \
|
|
||||||
editEnd.h
|
|
||||||
|
|
||||||
SOURCES += \
|
SOURCES += \
|
||||||
../../common/geometryutils.cpp \
|
../../common/geometryutils.cpp \
|
||||||
../CallManage/CallManage.cpp \
|
../CallManage/CallManage.cpp \
|
||||||
AngleAdjTool.cpp \
|
AngleAdjTool.cpp \
|
||||||
CStringType.cpp \
|
CStringType.cpp \
|
||||||
CurvePropertyEdit.cpp \
|
|
||||||
DrawCurveView.cpp \
|
|
||||||
MyWelllogRound.cpp \
|
MyWelllogRound.cpp \
|
||||||
ShowCurve.cpp \
|
|
||||||
SmoothTool.cpp \
|
SmoothTool.cpp \
|
||||||
TipPop.cpp \
|
TipPop.cpp \
|
||||||
WellDialog.cpp \
|
WellDialog.cpp \
|
||||||
|
|
@ -100,8 +89,6 @@ SOURCES += \
|
||||||
WellLogTableDialogNew.cpp \
|
WellLogTableDialogNew.cpp \
|
||||||
assetcopy.cpp \
|
assetcopy.cpp \
|
||||||
completertextedit.cpp \
|
completertextedit.cpp \
|
||||||
deptlineedit.cpp \
|
|
||||||
editEnd.cpp \
|
|
||||||
griddataadapter.cpp
|
griddataadapter.cpp
|
||||||
|
|
||||||
INCLUDEPATH += ../include
|
INCLUDEPATH += ../include
|
||||||
|
|
|
||||||
|
|
@ -1,67 +0,0 @@
|
||||||
#include "deptlineedit.h"
|
|
||||||
#include <QPaintEvent>
|
|
||||||
#include <QPainter>
|
|
||||||
#include <QStyleOptionFrameV2>
|
|
||||||
#include <QScrollBar>
|
|
||||||
#include <QGraphicsProxyWidget>
|
|
||||||
#include <QHBoxLayout>
|
|
||||||
#include <QTextCodec>
|
|
||||||
#include <QSpacerItem>
|
|
||||||
|
|
||||||
DeptLineEdit::DeptLineEdit(QWidget *parent)
|
|
||||||
: QGraphicsView(parent)
|
|
||||||
{
|
|
||||||
|
|
||||||
init();
|
|
||||||
}
|
|
||||||
|
|
||||||
DeptLineEdit::~DeptLineEdit()
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
void DeptLineEdit::init()
|
|
||||||
{
|
|
||||||
proxyWidget=NULL;
|
|
||||||
m_depWidget=NULL;
|
|
||||||
m_lbl=NULL;
|
|
||||||
this->setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
|
|
||||||
this->setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
|
|
||||||
|
|
||||||
m_depWidget=new QWidget();
|
|
||||||
m_depWidget->setFixedSize(200,35);
|
|
||||||
QHBoxLayout *hlayout=new QHBoxLayout();
|
|
||||||
lineEdit_Depth=new QLineEdit(m_depWidget);
|
|
||||||
lineEdit_Depth->setFixedSize(100,30);
|
|
||||||
lineEdit_Depth->setAlignment(Qt::AlignLeft|Qt::AlignVCenter);
|
|
||||||
lineEdit_Depth->setContentsMargins(0,0,0,0);
|
|
||||||
|
|
||||||
lineEdit_Depth->setStyleSheet("border:1px solid gray;");
|
|
||||||
m_lbl=new QLabel(m_depWidget);
|
|
||||||
m_lbl->setFixedHeight(30);
|
|
||||||
m_lbl->setText(tr("当前深度(m):"));//
|
|
||||||
hlayout->addStretch(1);
|
|
||||||
hlayout->addWidget(m_lbl,0,Qt::AlignHCenter);
|
|
||||||
hlayout->addWidget(lineEdit_Depth,1);
|
|
||||||
hlayout->addStretch(1);
|
|
||||||
hlayout->setContentsMargins(0,0,0,0);
|
|
||||||
m_lbl->setAlignment(Qt::AlignHCenter|Qt::AlignVCenter);
|
|
||||||
m_depWidget->setLayout(hlayout);
|
|
||||||
m_depWidget->setContentsMargins(0,0,0,0);
|
|
||||||
m_scene=new QGraphicsScene();
|
|
||||||
this->setScene(m_scene);
|
|
||||||
|
|
||||||
}
|
|
||||||
void DeptLineEdit::showEvent(QShowEvent *)
|
|
||||||
{
|
|
||||||
m_scene->setSceneRect(rect());
|
|
||||||
|
|
||||||
m_depWidget->setFixedSize(height(),width());
|
|
||||||
proxyWidget= m_scene->addWidget(m_depWidget);
|
|
||||||
this->setContentsMargins(0,0,0,0);
|
|
||||||
proxyWidget->setContentsMargins(0,0,0,0);
|
|
||||||
QPoint point=rect().center();
|
|
||||||
//proxyWidget->translate(0,point.y()+height()/2.+1);
|
|
||||||
proxyWidget->setRotation(-90);
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,39 +0,0 @@
|
||||||
#ifndef DEPTLINEEDIT_H
|
|
||||||
#define DEPTLINEEDIT_H
|
|
||||||
|
|
||||||
#include <QWidget>
|
|
||||||
#include <QLineEdit>
|
|
||||||
#include <QGraphicsProxyWidget>
|
|
||||||
#include <QGraphicsView>
|
|
||||||
#include <QLineEdit>
|
|
||||||
#include <QLabel>
|
|
||||||
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
|
|
||||||
/*自定义输入控件*/
|
|
||||||
class DeptLineEdit : public QGraphicsView
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
public:
|
|
||||||
DeptLineEdit(QWidget *parent);
|
|
||||||
~DeptLineEdit();
|
|
||||||
QLineEdit *lineEdit_Depth;
|
|
||||||
QLabel *m_lbl;
|
|
||||||
// QWidget interface
|
|
||||||
protected:
|
|
||||||
void showEvent(QShowEvent *);
|
|
||||||
private:
|
|
||||||
void init();
|
|
||||||
private:
|
|
||||||
|
|
||||||
QGraphicsScene *m_scene;
|
|
||||||
private:
|
|
||||||
QRect m_rect;
|
|
||||||
QGraphicsProxyWidget* proxyWidget;
|
|
||||||
QWidget *m_depWidget;
|
|
||||||
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // DEPTLINEEDIT_H
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
||||||
#include "editEnd.h"
|
|
||||||
#include "ui_editEnd.h"
|
|
||||||
|
|
||||||
editEnd::editEnd(QDialog *parent) :
|
|
||||||
QDialog(parent),
|
|
||||||
ui(new Ui::editEnd)
|
|
||||||
{
|
|
||||||
ui->setupUi(this);
|
|
||||||
ui->radioButton->setChecked(true);
|
|
||||||
|
|
||||||
connect(ui->radioButton, SIGNAL(toggled(bool)), this, SLOT(smChooseChange_SLOT()));
|
|
||||||
connect(ui->radioButton_2, SIGNAL(toggled(bool)), this, SLOT(smChooseChange_SLOT()));
|
|
||||||
connect(ui->radioButton_3, SIGNAL(toggled(bool)), this, SLOT(smChooseChange_SLOT()));
|
|
||||||
connect(ui->pushButton, SIGNAL(clicked()), this, SLOT(reject()));
|
|
||||||
connect(ui->pushButton, SIGNAL(clicked()), this, SLOT(continueEdit_SLOT()));
|
|
||||||
}
|
|
||||||
|
|
||||||
editEnd::~editEnd()
|
|
||||||
{
|
|
||||||
delete ui;
|
|
||||||
}
|
|
||||||
|
|
||||||
void editEnd::continueEdit_SLOT()
|
|
||||||
{
|
|
||||||
emit sendContinueSignal();
|
|
||||||
}
|
|
||||||
|
|
||||||
int editEnd::SmoothResult(){
|
|
||||||
if(ui->radioButton_3->isChecked())
|
|
||||||
return 1;
|
|
||||||
else if(ui->radioButton_2->isChecked())
|
|
||||||
return 2;
|
|
||||||
else
|
|
||||||
return 3;
|
|
||||||
}
|
|
||||||
|
|
||||||
void editEnd::smChooseChange_SLOT()
|
|
||||||
{
|
|
||||||
if(ui->radioButton_3->isChecked())
|
|
||||||
emit sendSmData(1);
|
|
||||||
else if(ui->radioButton_2->isChecked())
|
|
||||||
emit sendSmData(2);
|
|
||||||
else
|
|
||||||
emit sendSmData(3);
|
|
||||||
}
|
|
||||||
|
|
@ -1,33 +0,0 @@
|
||||||
#ifndef EDITEND_H
|
|
||||||
#define EDITEND_H
|
|
||||||
|
|
||||||
#include <QDialog>
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
|
|
||||||
namespace Ui {
|
|
||||||
class editEnd;
|
|
||||||
}
|
|
||||||
|
|
||||||
class editEnd : public QDialog
|
|
||||||
{
|
|
||||||
Q_OBJECT
|
|
||||||
|
|
||||||
signals:
|
|
||||||
void sendSmData(int);
|
|
||||||
void sendContinueSignal();
|
|
||||||
|
|
||||||
public:
|
|
||||||
explicit editEnd(QDialog *parent = 0);
|
|
||||||
~editEnd();
|
|
||||||
|
|
||||||
int SmoothResult();
|
|
||||||
private:
|
|
||||||
Ui::editEnd *ui;
|
|
||||||
|
|
||||||
private slots:
|
|
||||||
void smChooseChange_SLOT();
|
|
||||||
void continueEdit_SLOT();
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif // EDITEND_H
|
|
||||||
|
|
@ -1,184 +0,0 @@
|
||||||
<?xml version="1.0" encoding="UTF-8"?>
|
|
||||||
<ui version="4.0">
|
|
||||||
<class>editEnd</class>
|
|
||||||
<widget class="QDialog" name="editEnd">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>0</x>
|
|
||||||
<y>0</y>
|
|
||||||
<width>391</width>
|
|
||||||
<height>213</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="windowTitle">
|
|
||||||
<string>Dialog</string>
|
|
||||||
</property>
|
|
||||||
<widget class="QWidget" name="verticalLayoutWidget">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>10</x>
|
|
||||||
<y>70</y>
|
|
||||||
<width>371</width>
|
|
||||||
<height>81</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<layout class="QVBoxLayout" name="verticalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="QGroupBox" name="groupBox">
|
|
||||||
<property name="title">
|
|
||||||
<string>平滑选项</string>
|
|
||||||
</property>
|
|
||||||
<widget class="QWidget" name="horizontalLayoutWidget_2">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>20</x>
|
|
||||||
<y>20</y>
|
|
||||||
<width>331</width>
|
|
||||||
<height>41</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton_3">
|
|
||||||
<property name="text">
|
|
||||||
<string>3点平滑</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton_2">
|
|
||||||
<property name="text">
|
|
||||||
<string>5点平滑</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item>
|
|
||||||
<widget class="QRadioButton" name="radioButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>不平滑</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
<widget class="QLabel" name="label">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>70</x>
|
|
||||||
<y>10</y>
|
|
||||||
<width>261</width>
|
|
||||||
<height>61</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<property name="font">
|
|
||||||
<font>
|
|
||||||
<pointsize>11</pointsize>
|
|
||||||
</font>
|
|
||||||
</property>
|
|
||||||
<property name="layoutDirection">
|
|
||||||
<enum>Qt::LeftToRight</enum>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>已完成编辑!是否替换原曲线?</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
<widget class="QWidget" name="layoutWidget">
|
|
||||||
<property name="geometry">
|
|
||||||
<rect>
|
|
||||||
<x>10</x>
|
|
||||||
<y>160</y>
|
|
||||||
<width>369</width>
|
|
||||||
<height>41</height>
|
|
||||||
</rect>
|
|
||||||
</property>
|
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="QPushButton" name="okButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>是</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="cancelButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>否</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>
|
|
||||||
<widget class="QPushButton" name="pushButton">
|
|
||||||
<property name="text">
|
|
||||||
<string>继续编辑</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
</layout>
|
|
||||||
</widget>
|
|
||||||
</widget>
|
|
||||||
<resources/>
|
|
||||||
<connections>
|
|
||||||
<connection>
|
|
||||||
<sender>okButton</sender>
|
|
||||||
<signal>clicked()</signal>
|
|
||||||
<receiver>editEnd</receiver>
|
|
||||||
<slot>accept()</slot>
|
|
||||||
<hints>
|
|
||||||
<hint type="sourcelabel">
|
|
||||||
<x>351</x>
|
|
||||||
<y>38</y>
|
|
||||||
</hint>
|
|
||||||
<hint type="destinationlabel">
|
|
||||||
<x>233</x>
|
|
||||||
<y>29</y>
|
|
||||||
</hint>
|
|
||||||
</hints>
|
|
||||||
</connection>
|
|
||||||
<connection>
|
|
||||||
<sender>cancelButton</sender>
|
|
||||||
<signal>clicked()</signal>
|
|
||||||
<receiver>editEnd</receiver>
|
|
||||||
<slot>reject()</slot>
|
|
||||||
<hints>
|
|
||||||
<hint type="sourcelabel">
|
|
||||||
<x>330</x>
|
|
||||||
<y>66</y>
|
|
||||||
</hint>
|
|
||||||
<hint type="destinationlabel">
|
|
||||||
<x>197</x>
|
|
||||||
<y>125</y>
|
|
||||||
</hint>
|
|
||||||
</hints>
|
|
||||||
</connection>
|
|
||||||
</connections>
|
|
||||||
</ui>
|
|
||||||
|
|
@ -827,6 +827,30 @@ int GetCurvInfo(QString strSlfName, QString strLineName, double &sdep, double &e
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int GetCurvValue(QString strSlfName, QString strLineName, QList<double> new_DepthList, QList<double> &new_ValueList)
|
||||||
|
{
|
||||||
|
CLogIO *logio=new CLogIO();
|
||||||
|
logio->Open(strSlfName.toStdString().c_str(),CSlfIO::modeRead);
|
||||||
|
//
|
||||||
|
int index=logio->OpenCurve(strLineName.toStdString().c_str());
|
||||||
|
if(index<0) {
|
||||||
|
delete logio;
|
||||||
|
return -1;
|
||||||
|
}
|
||||||
|
|
||||||
|
float fValue=-9999;
|
||||||
|
for(int i=0; i<new_DepthList.size(); i++)
|
||||||
|
{
|
||||||
|
logio->ReadCurve(index, 0-new_DepthList[i], 1, &fValue);
|
||||||
|
new_ValueList.append(fValue);
|
||||||
|
}
|
||||||
|
//
|
||||||
|
logio->CloseCurve(index);
|
||||||
|
delete logio;
|
||||||
|
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
bool getAliasNameFromIni(QString CurveName, QString &strAliasName, QString &strUnit)
|
bool getAliasNameFromIni(QString CurveName, QString &strAliasName, QString &strUnit)
|
||||||
{
|
{
|
||||||
QString curveFamilyFilePath = ::GetConfPath() + "CurveFamily_New.ini";
|
QString curveFamilyFilePath = ::GetConfPath() + "CurveFamily_New.ini";
|
||||||
|
|
|
||||||
|
|
@ -202,6 +202,7 @@ void SetSystemExisting(bool exiting);
|
||||||
bool SystemExiting();
|
bool SystemExiting();
|
||||||
bool getAllSlf(QString prjname, QVector<QString> &vecSlfList, QVector<QString> &vecWellList);//直方图,获取当前工程下的slf
|
bool getAllSlf(QString prjname, QVector<QString> &vecSlfList, QVector<QString> &vecWellList);//直方图,获取当前工程下的slf
|
||||||
int GetCurvInfo(QString strSlfName, QString strLineName, double &sdep, double &edep, double &rlev);//获取曲线顶深、底深、间隔
|
int GetCurvInfo(QString strSlfName, QString strLineName, double &sdep, double &edep, double &rlev);//获取曲线顶深、底深、间隔
|
||||||
|
int GetCurvValue(QString strSlfName, QString strLineName, QList<double> new_DepthList, QList<double> &new_ValueList);//获取指定刻度的曲线值
|
||||||
bool getAliasNameFromIni(QString CurveName, QString &strAliasName, QString &strUnit);//曲线别名,单位
|
bool getAliasNameFromIni(QString CurveName, QString &strAliasName, QString &strUnit);//曲线别名,单位
|
||||||
/**
|
/**
|
||||||
* @brief 获取系统缺省的系统颜色
|
* @brief 获取系统缺省的系统颜色
|
||||||
|
|
|
||||||
|
|
@ -1015,7 +1015,7 @@ int DepPairs::joincurve(float sdeps,float edeps,float *datx1,float *daty1,float
|
||||||
fp_temp=fopen(dir.toStdString().c_str(),"w+");
|
fp_temp=fopen(dir.toStdString().c_str(),"w+");
|
||||||
if(fp_temp==NULL)
|
if(fp_temp==NULL)
|
||||||
{
|
{
|
||||||
QMessageBox::warning(nullptr, "提示", "Not create file :admtemp !\n");
|
QMessageBox::warning(nullptr, "提示", "Not create file :admtemp !");
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1164,7 +1164,7 @@ int DepPairs::adm(float stem,float etem ,float cmins,
|
||||||
fp_temp=fopen(dir.toStdString().c_str(),"rt");
|
fp_temp=fopen(dir.toStdString().c_str(),"rt");
|
||||||
if(fp_temp==NULL)
|
if(fp_temp==NULL)
|
||||||
{
|
{
|
||||||
QMessageBox::warning(nullptr, "提示", "Not create file :admtemp !\n");
|
QMessageBox::warning(nullptr, "提示", "Not create file :admtemp !");
|
||||||
delete [] datx;
|
delete [] datx;
|
||||||
delete [] daty;
|
delete [] daty;
|
||||||
delete [] datc;
|
delete [] datc;
|
||||||
|
|
|
||||||
|
|
@ -82,6 +82,7 @@ SOURCES += \
|
||||||
qtprojectwidgets.cpp \
|
qtprojectwidgets.cpp \
|
||||||
totalTitleBar.cpp \
|
totalTitleBar.cpp \
|
||||||
transparentdraggableGuan.cpp \
|
transparentdraggableGuan.cpp \
|
||||||
|
transparentdraggableRightList.cpp \
|
||||||
transparentdraggableSelectRect.cpp \
|
transparentdraggableSelectRect.cpp \
|
||||||
transparentdraggableimage.cpp \
|
transparentdraggableimage.cpp \
|
||||||
variantfactory.cpp \
|
variantfactory.cpp \
|
||||||
|
|
@ -143,6 +144,7 @@ HEADERS += \
|
||||||
qtprojectwidgets.h \
|
qtprojectwidgets.h \
|
||||||
totalTitleBar.h \
|
totalTitleBar.h \
|
||||||
transparentdraggableGuan.h \
|
transparentdraggableGuan.h \
|
||||||
|
transparentdraggableRightList.h \
|
||||||
transparentdraggableSelectRect.h \
|
transparentdraggableSelectRect.h \
|
||||||
transparentdraggableimage.h \
|
transparentdraggableimage.h \
|
||||||
variantfactory.h \
|
variantfactory.h \
|
||||||
|
|
|
||||||
|
|
@ -135,6 +135,9 @@ MainWindowCurve::MainWindowCurve(QWidget *parent) :
|
||||||
//执行拼接
|
//执行拼接
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_Merge_List(QString, QList<double>, QList<double>)), this, SLOT(s_Merge_List(QString, QList<double>, QList<double>)));
|
connect(CallManage::getInstance(), SIGNAL(sig_Merge_List(QString, QList<double>, QList<double>)), this, SLOT(s_Merge_List(QString, QList<double>, QList<double>)));
|
||||||
|
|
||||||
|
//执行预览
|
||||||
|
connect(CallManage::getInstance(), SIGNAL(sig_PreMerge_List(QString, QString, QString, QString, QString, QList<double>, QList<double>)), this, SLOT(s_PreMerge_List(QString, QString, QString, QString, QString, QList<double>, QList<double>)));
|
||||||
|
|
||||||
//执行压缩/拉伸
|
//执行压缩/拉伸
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_EShiftDepth(QString, QString, int, QList<double>, QList<double>)), this, SLOT(s_EShiftDepth(QString, QString, int, QList<double>, QList<double>)));
|
connect(CallManage::getInstance(), SIGNAL(sig_EShiftDepth(QString, QString, int, QList<double>, QList<double>)), this, SLOT(s_EShiftDepth(QString, QString, int, QList<double>, QList<double>)));
|
||||||
|
|
||||||
|
|
@ -568,7 +571,7 @@ void MainWindowCurve::initToolBar_3()
|
||||||
ui->toolBar_3->addAction(m_CorrectionAc);
|
ui->toolBar_3->addAction(m_CorrectionAc);
|
||||||
//ui->toolBar_3->addAction(m_ShiftotherAc);
|
//ui->toolBar_3->addAction(m_ShiftotherAc);
|
||||||
ui->toolBar_3->addSeparator();
|
ui->toolBar_3->addSeparator();
|
||||||
//ui->toolBar_3->addAction(m_PreMegAc);
|
ui->toolBar_3->addAction(m_PreMegAc);
|
||||||
ui->toolBar_3->addAction(m_mergeAc);
|
ui->toolBar_3->addAction(m_mergeAc);
|
||||||
ui->toolBar_3->addSeparator();
|
ui->toolBar_3->addSeparator();
|
||||||
ui->toolBar_3->addAction(m_ClearAllSetCurveAc);
|
ui->toolBar_3->addAction(m_ClearAllSetCurveAc);
|
||||||
|
|
@ -577,7 +580,7 @@ void MainWindowCurve::initToolBar_3()
|
||||||
connect(m_StandardAc, &QAction::triggered, this, &MainWindowCurve::s_Standard);
|
connect(m_StandardAc, &QAction::triggered, this, &MainWindowCurve::s_Standard);
|
||||||
connect(m_CorrectionAc, &QAction::triggered, this, &MainWindowCurve::s_Correction);
|
connect(m_CorrectionAc, &QAction::triggered, this, &MainWindowCurve::s_Correction);
|
||||||
//// connect(m_ShiftotherAc, &QAction::triggered, this, &MainWindowCurve::s_Shiftother);
|
//// connect(m_ShiftotherAc, &QAction::triggered, this, &MainWindowCurve::s_Shiftother);
|
||||||
// connect(m_autocorAc, &QAction::triggered, this, &MainWindowCurve::s_autocor);
|
connect(m_PreMegAc, &QAction::triggered, this, &MainWindowCurve::s_PreMegAc);
|
||||||
connect(m_mergeAc, &QAction::triggered, this, &MainWindowCurve::s_merge);
|
connect(m_mergeAc, &QAction::triggered, this, &MainWindowCurve::s_merge);
|
||||||
connect(m_ClearAllSetCurveAc, &QAction::triggered, this, &MainWindowCurve::s_ClearAllSetCurve);
|
connect(m_ClearAllSetCurveAc, &QAction::triggered, this, &MainWindowCurve::s_ClearAllSetCurve);
|
||||||
connect(m_ClearSetCurveAc, &QAction::triggered, this, &MainWindowCurve::s_ClearSetCurve);
|
connect(m_ClearSetCurveAc, &QAction::triggered, this, &MainWindowCurve::s_ClearSetCurve);
|
||||||
|
|
@ -1579,6 +1582,153 @@ void MainWindowCurve::s_Runcor_List(QString strUuid, QList<double> left_Low_List
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//拼接预览
|
||||||
|
void MainWindowCurve::s_PreMegAc()
|
||||||
|
{
|
||||||
|
//当前有标准(目标)曲线
|
||||||
|
if(m_LeftCurve.m_iTableType==3 && m_LeftCurve.m_strFormInfoType=="curveObject")
|
||||||
|
{
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "请先选择目标曲线!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//当前有主校(源拼接)曲线
|
||||||
|
if(m_RightCurve.m_iTableType==3 && m_RightCurve.m_strFormInfoType=="curveObject")
|
||||||
|
{
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "请先选择源拼接曲线!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//通知界面,执行预览
|
||||||
|
emit CallManage::getInstance()->sig_PreMergeFromPlot(m_strUuid, m_LeftCurve.m_strSlfName, m_LeftCurve.m_strWellName, m_LeftCurve.m_strTrackName, m_LeftCurve.m_strLineName);
|
||||||
|
}
|
||||||
|
|
||||||
|
void MainWindowCurve::s_PreMerge_List(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> left_Low_List, QList<double> right_Hight_List)
|
||||||
|
{
|
||||||
|
if(strUuid != m_strUuid)
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//当前有标准(目标)曲线
|
||||||
|
if(m_LeftCurve.m_iTableType==3 && m_LeftCurve.m_strFormInfoType=="curveObject")
|
||||||
|
{
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "无目标井!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//当前有主校(源拼接)曲线
|
||||||
|
if(m_RightCurve.m_iTableType==3 && m_RightCurve.m_strFormInfoType=="curveObject")
|
||||||
|
{
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "缺少目标曲线或目标曲线无效!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
m_mergeLineList.clear();
|
||||||
|
//
|
||||||
|
int pointnum =left_Low_List.size();
|
||||||
|
|
||||||
|
//
|
||||||
|
for(int i=0;i<pointnum;i++)
|
||||||
|
{
|
||||||
|
CurveLine * pLine = new CurveLine();
|
||||||
|
pLine->SetLeftDepth(left_Low_List[i]);
|
||||||
|
pLine->SetRightDepth(right_Hight_List[i]);
|
||||||
|
m_mergeLineList.append(pLine);
|
||||||
|
}
|
||||||
|
qsort(m_mergeLineList,0,m_mergeLineList.size()-1,0);
|
||||||
|
|
||||||
|
if(pointnum<1) {
|
||||||
|
QMessageBox::warning(this, "提示", "曲线拼接深度点不存在,无法拼接!请先设置拼接深度点。");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(pointnum>2) {
|
||||||
|
QMessageBox::warning(this, "提示", "曲线拼接深度点太多,最多可设置2点!请重新设置拼接深度点。");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
float SourSdep=0;
|
||||||
|
float SourEdep=0;
|
||||||
|
float DectSdep=0;
|
||||||
|
if(pointnum==1) {
|
||||||
|
QMessageBox box(QMessageBox::Warning,"提示","拼接深度点仅有1个,请您选择拼接部位");
|
||||||
|
box.setStandardButtons (QMessageBox::Yes|QMessageBox::No|QMessageBox::Cancel);
|
||||||
|
box.setButtonText(QMessageBox::Yes,QString("拼接上段"));
|
||||||
|
box.setButtonText(QMessageBox::No,QString("拼接下段"));
|
||||||
|
box.setButtonText(QMessageBox::Cancel,QString("放弃"));
|
||||||
|
int flag=box.exec();//QMessageBox::information(NULL,"敬告",pwelllog->GetName()+mess,QMessageBox::Yes,QMessageBox::No,QMessageBox::Cancel);
|
||||||
|
|
||||||
|
double sdep_right = 0;
|
||||||
|
double edep_right = 0;
|
||||||
|
double rlev_right = 0;
|
||||||
|
//获取曲线顶深、底深、间隔
|
||||||
|
int iRet = GetCurvInfo(m_RightCurve.m_strSlfName, m_RightCurve.m_strLineName, sdep_right, edep_right, rlev_right);
|
||||||
|
if(iRet!=1)
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "曲线深度读取失败,无法拼接!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
if(flag==QMessageBox::Yes) {
|
||||||
|
SourSdep=sdep_right;
|
||||||
|
SourEdep=m_mergeLineList[0]->GetLeftDepth();
|
||||||
|
DectSdep=SourSdep;
|
||||||
|
}
|
||||||
|
else if(flag==QMessageBox::No) {
|
||||||
|
DectSdep=m_mergeLineList[0]->GetLeftDepth();
|
||||||
|
SourEdep=edep_right;
|
||||||
|
SourSdep=m_mergeLineList[0]->GetRightDepth();
|
||||||
|
}
|
||||||
|
else return;
|
||||||
|
}
|
||||||
|
else if(pointnum==2) {
|
||||||
|
SourSdep=m_mergeLineList[0]->GetLeftDepth();//+m_RightCurve->GetShiftOffset();
|
||||||
|
SourEdep=m_mergeLineList[1]->GetLeftDepth();//+m_RightCurve->GetShiftOffset();
|
||||||
|
DectSdep=m_mergeLineList[0]->GetLeftDepth();
|
||||||
|
}
|
||||||
|
|
||||||
|
//---------------
|
||||||
|
double sdep_left = 0;
|
||||||
|
double edep_left = 0;
|
||||||
|
double rlev_left = 0;
|
||||||
|
//获取曲线顶深、底深、间隔
|
||||||
|
int iRet = GetCurvInfo(m_LeftCurve.m_strSlfName, m_LeftCurve.m_strLineName, sdep_left, edep_left, rlev_left);
|
||||||
|
if(iRet!=1)
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "曲线深度读取失败,无法拼接!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//
|
||||||
|
QList<double> new_DepthList;
|
||||||
|
QList<double> new_ValueList;
|
||||||
|
int size1=(SourEdep-SourSdep)/rlev_left+1.5;
|
||||||
|
if(size1>0) {
|
||||||
|
float dep=0;
|
||||||
|
for(int i=0;i<size1;i++) {
|
||||||
|
dep=SourSdep+i*rlev_left;
|
||||||
|
new_DepthList.append(0-dep);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
iRet = GetCurvValue(m_RightCurve.m_strSlfName, m_RightCurve.m_strLineName, new_DepthList, new_ValueList);
|
||||||
|
if(iRet!=1)
|
||||||
|
{
|
||||||
|
QMessageBox::warning(this, "提示", "曲线数据读取失败,无法拼接!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
//采用右侧数据,执行预览
|
||||||
|
emit CallManage::getInstance()->sig_PreMerge_FromRightList(m_strUuid, strSlfName, strWellName, strTrackName, strLineName, new_DepthList, new_ValueList);
|
||||||
|
}
|
||||||
|
|
||||||
//执行拼接
|
//执行拼接
|
||||||
void MainWindowCurve::s_merge()
|
void MainWindowCurve::s_merge()
|
||||||
{
|
{
|
||||||
|
|
@ -1602,7 +1752,7 @@ void MainWindowCurve::s_merge()
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//通知界面,执行校正
|
//通知界面,执行拼接
|
||||||
emit CallManage::getInstance()->sig_MergeFromPlot(m_strUuid, m_LeftCurve.m_strSlfName, m_LeftCurve.m_strWellName, m_LeftCurve.m_strTrackName, m_LeftCurve.m_strLineName);
|
emit CallManage::getInstance()->sig_MergeFromPlot(m_strUuid, m_LeftCurve.m_strSlfName, m_LeftCurve.m_strWellName, m_LeftCurve.m_strTrackName, m_LeftCurve.m_strLineName);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1648,11 +1798,11 @@ void MainWindowCurve::s_Merge_List(QString strUuid, QList<double> left_Low_List,
|
||||||
qsort(m_mergeLineList,0,m_mergeLineList.size()-1,0);
|
qsort(m_mergeLineList,0,m_mergeLineList.size()-1,0);
|
||||||
|
|
||||||
if(pointnum<1) {
|
if(pointnum<1) {
|
||||||
QMessageBox::warning(this, "提示", "曲线拼接深度点不存在,无法拼接!\n请先设置拼接深度点。");
|
QMessageBox::warning(this, "提示", "曲线拼接深度点不存在,无法拼接!请先设置拼接深度点。");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if(pointnum>2) {
|
if(pointnum>2) {
|
||||||
QMessageBox::warning(this, "提示", "曲线拼接深度点太多,最多可设置2点!\n请重新设置拼接深度点。");
|
QMessageBox::warning(this, "提示", "曲线拼接深度点太多,最多可设置2点!请重新设置拼接深度点。");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1812,6 +1962,8 @@ void MainWindowCurve::s_Merge_List(QString strUuid, QList<double> left_Low_List,
|
||||||
|
|
||||||
//Plot重新加载数据
|
//Plot重新加载数据
|
||||||
emit CallManage::getInstance()->sig_ReloadPlot(m_strUuid, filename1, name1);
|
emit CallManage::getInstance()->sig_ReloadPlot(m_strUuid, filename1, name1);
|
||||||
|
//关闭预览框
|
||||||
|
emit CallManage::getInstance()->sig_PreMerge_Close(m_strUuid, m_LeftCurve.m_strSlfName, m_LeftCurve.m_strWellName, m_LeftCurve.m_strTrackName, m_LeftCurve.m_strLineName);
|
||||||
|
|
||||||
if(ERRORS.size())QMessageBox::warning(this, "提示", "目标曲线不存在:"+ERRORS.join(" "));
|
if(ERRORS.size())QMessageBox::warning(this, "提示", "目标曲线不存在:"+ERRORS.join(" "));
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -219,6 +219,10 @@ public slots:
|
||||||
void s_merge();
|
void s_merge();
|
||||||
void s_Merge_List(QString strUuid, QList<double> left_Low_List, QList<double> right_Hight_List);
|
void s_Merge_List(QString strUuid, QList<double> left_Low_List, QList<double> right_Hight_List);
|
||||||
|
|
||||||
|
//拼接预览
|
||||||
|
void s_PreMegAc();
|
||||||
|
void s_PreMerge_List(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> left_Low_List, QList<double> right_Hight_List);
|
||||||
|
|
||||||
//编辑曲线,框选拉伸/压缩
|
//编辑曲线,框选拉伸/压缩
|
||||||
void s_EShiftDepth(QString strSlfName, QString strLineName, int count, QList<double> left_Low_List, QList<double> right_Hight_List);
|
void s_EShiftDepth(QString strSlfName, QString strLineName, int count, QList<double> left_Low_List, QList<double> right_Hight_List);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -14,6 +14,7 @@
|
||||||
#include "transparentdraggableGuan.h"
|
#include "transparentdraggableGuan.h"
|
||||||
#include "TransparentDraggableLine.h"
|
#include "TransparentDraggableLine.h"
|
||||||
#include "transparentdraggableSelectRect.h"
|
#include "transparentdraggableSelectRect.h"
|
||||||
|
#include "transparentdraggableRightList.h"
|
||||||
#include "qtcommonclass.h"
|
#include "qtcommonclass.h"
|
||||||
|
|
||||||
//是否隐藏刻度
|
//是否隐藏刻度
|
||||||
|
|
@ -89,6 +90,12 @@ QMyCustomPlot::QMyCustomPlot(QWidget *parent, QString strSlfName, QString strWel
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_RuncorFromPlot(QString, QString, QString, QString, QString)), this, SLOT(s_RuncorFromPlot(QString, QString, QString, QString, QString)));
|
connect(CallManage::getInstance(), SIGNAL(sig_RuncorFromPlot(QString, QString, QString, QString, QString)), this, SLOT(s_RuncorFromPlot(QString, QString, QString, QString, QString)));
|
||||||
//执行拼接
|
//执行拼接
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_MergeFromPlot(QString, QString, QString, QString, QString)), this, SLOT(s_MergeFromPlot(QString, QString, QString, QString, QString)));
|
connect(CallManage::getInstance(), SIGNAL(sig_MergeFromPlot(QString, QString, QString, QString, QString)), this, SLOT(s_MergeFromPlot(QString, QString, QString, QString, QString)));
|
||||||
|
//执行预览
|
||||||
|
connect(CallManage::getInstance(), SIGNAL(sig_PreMergeFromPlot(QString, QString, QString, QString, QString)), this, SLOT(s_PreMergeFromPlot(QString, QString, QString, QString, QString)));
|
||||||
|
//采用右侧数据,执行预览
|
||||||
|
connect(CallManage::getInstance(), SIGNAL(sig_PreMerge_FromRightList(QString, QString, QString, QString, QString, QList<double>, QList<double>)), this, SLOT(s_PreMerge_FromRightList(QString, QString, QString, QString, QString, QList<double>, QList<double>)));
|
||||||
|
//关闭预览框
|
||||||
|
connect(CallManage::getInstance(), SIGNAL(sig_PreMerge_Close(QString, QString, QString, QString, QString)), this, SLOT(s_PreMerge_Close(QString, QString, QString, QString, QString)));
|
||||||
|
|
||||||
//Plot重新加载数据
|
//Plot重新加载数据
|
||||||
connect(CallManage::getInstance(), SIGNAL(sig_ReloadPlot(QString, QString, QString)), this, SLOT(s_ReloadPlot(QString, QString, QString)));
|
connect(CallManage::getInstance(), SIGNAL(sig_ReloadPlot(QString, QString, QString)), this, SLOT(s_ReloadPlot(QString, QString, QString)));
|
||||||
|
|
@ -636,6 +643,29 @@ void QMyCustomPlot::addSelectRectToPlot(double left_Low, double right_Hight, int
|
||||||
m_mapDraggable_SelectRect[strUuid] = dragRect;
|
m_mapDraggable_SelectRect[strUuid] = dragRect;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//预览
|
||||||
|
void QMyCustomPlot::addRightListToPlot( QList<double> new_DepthList, QList<double> new_ValueListt)
|
||||||
|
{
|
||||||
|
//qDebug() << "QMyCustomPlot addSelectRectToPlot";
|
||||||
|
|
||||||
|
QtCommonClass *qtCommon = new QtCommonClass(this);
|
||||||
|
QString strUuid = qtCommon->getUUid();
|
||||||
|
|
||||||
|
// 在初始化代码中
|
||||||
|
TransparentDraggableRightList *dragRect = new TransparentDraggableRightList(this, strUuid);
|
||||||
|
//图片,提前设值,后面setRange改变
|
||||||
|
dragRect->setRightList(new_DepthList, new_ValueListt);
|
||||||
|
// 设置初始范围
|
||||||
|
dragRect->setRange(new_DepthList[new_DepthList.size()-1], new_DepthList[0]);
|
||||||
|
// 可选:设置颜色
|
||||||
|
dragRect->setColor(QColor(255, 255, 255, 80)); // 半透明红色
|
||||||
|
//最小宽度
|
||||||
|
dragRect->setMinWidth(0.1);
|
||||||
|
//dragRect->setTitle(strText);
|
||||||
|
|
||||||
|
m_mapDraggable_RightList[strUuid] = dragRect;
|
||||||
|
}
|
||||||
|
|
||||||
//校深线段
|
//校深线段
|
||||||
void QMyCustomPlot::s_AddShifLineToPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, double left_Low, double right_Hight)
|
void QMyCustomPlot::s_AddShifLineToPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, double left_Low, double right_Hight)
|
||||||
{
|
{
|
||||||
|
|
@ -737,7 +767,7 @@ void QMyCustomPlot::s_RuncorFromPlot(QString strUuid, QString strSlfName, QStrin
|
||||||
|
|
||||||
if(left_Low_List.size()<=0)
|
if(left_Low_List.size()<=0)
|
||||||
{
|
{
|
||||||
QMessageBox::warning(this, "提示", "无校正深度线或深度移动量!");
|
QMessageBox::warning(nullptr, "提示", "无校正深度线或深度移动量!");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -778,7 +808,7 @@ void QMyCustomPlot::s_MergeFromPlot(QString strUuid, QString strSlfName, QString
|
||||||
|
|
||||||
if(left_Low_List.size()<=0)
|
if(left_Low_List.size()<=0)
|
||||||
{
|
{
|
||||||
QMessageBox::warning(this, "提示", "曲线拼接深度点不存在,无法拼接!\n请先设置拼接深度点。");
|
QMessageBox::warning(nullptr, "提示", "曲线拼接深度点不存在,无法拼接!请先设置拼接深度点。");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -786,6 +816,93 @@ void QMyCustomPlot::s_MergeFromPlot(QString strUuid, QString strSlfName, QString
|
||||||
emit CallManage::getInstance()->sig_Merge_List(m_strUuid, left_Low_List, right_Hight_List);
|
emit CallManage::getInstance()->sig_Merge_List(m_strUuid, left_Low_List, right_Hight_List);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//关闭预览框
|
||||||
|
void QMyCustomPlot::s_PreMerge_Close(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName)
|
||||||
|
{
|
||||||
|
if(m_strUuid == strUuid &&
|
||||||
|
m_strSlfName == strSlfName &&
|
||||||
|
m_strWellName == strWellName &&
|
||||||
|
m_strTrackName == strTrackName &&
|
||||||
|
m_strLineName == strLineName)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
TransparentDraggableRightList *pDraggableRect =NULL;
|
||||||
|
{
|
||||||
|
QMap<QString,QObject *>::Iterator it = this->m_mapDraggable_RightList.begin();
|
||||||
|
if( it != this->m_mapDraggable_RightList.end() )
|
||||||
|
{
|
||||||
|
pDraggableRect = (TransparentDraggableRightList*)it.value();
|
||||||
|
pDraggableRect->deleteRect();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
void QMyCustomPlot::s_PreMerge_FromRightList(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> new_DepthList, QList<double> new_ValueList)
|
||||||
|
{
|
||||||
|
if(m_strUuid == strUuid &&
|
||||||
|
m_strSlfName == strSlfName &&
|
||||||
|
m_strWellName == strWellName &&
|
||||||
|
m_strTrackName == strTrackName &&
|
||||||
|
m_strLineName == strLineName)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//预览
|
||||||
|
addRightListToPlot(new_DepthList, new_ValueList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//执行预览
|
||||||
|
void QMyCustomPlot::s_PreMergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName)
|
||||||
|
{
|
||||||
|
if(m_strUuid == strUuid &&
|
||||||
|
m_strSlfName == strSlfName &&
|
||||||
|
m_strWellName == strWellName &&
|
||||||
|
m_strTrackName == strTrackName &&
|
||||||
|
m_strLineName == strLineName)
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
QList<double> left_Low_List;
|
||||||
|
QList<double> right_Hight_List;
|
||||||
|
|
||||||
|
TransparentDraggableLine *pDraggableLine =NULL;
|
||||||
|
QMap<QString,QObject *>::Iterator it = m_mapDraggable_Line.begin();
|
||||||
|
while( it != m_mapDraggable_Line.end() )
|
||||||
|
{
|
||||||
|
pDraggableLine = (TransparentDraggableLine*)it.value();
|
||||||
|
left_Low_List.append(0-pDraggableLine->m_left_Low);
|
||||||
|
right_Hight_List.append(0-pDraggableLine->m_right_Hight);
|
||||||
|
|
||||||
|
//
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
|
||||||
|
if(left_Low_List.size()<=0)
|
||||||
|
{
|
||||||
|
QMessageBox::warning(nullptr, "提示", "曲线拼接深度点不存在,无法拼接!请先设置拼接深度点。");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//执行预览
|
||||||
|
emit CallManage::getInstance()->sig_PreMerge_List(m_strUuid, m_strSlfName, m_strWellName, m_strTrackName, m_strLineName, left_Low_List, right_Hight_List);
|
||||||
|
}
|
||||||
|
|
||||||
//Plot重新加载数据
|
//Plot重新加载数据
|
||||||
void QMyCustomPlot::s_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName)
|
void QMyCustomPlot::s_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -86,6 +86,7 @@ public:
|
||||||
bool m_addRandomGraph=false;//当前是否绘制曲线 true:是。
|
bool m_addRandomGraph=false;//当前是否绘制曲线 true:是。
|
||||||
bool m_bEditRect=false; //当前是否正在编辑曲线。
|
bool m_bEditRect=false; //当前是否正在编辑曲线。
|
||||||
bool m_bFirstTimeConnect=true; //初次绑定编辑曲线信号槽。
|
bool m_bFirstTimeConnect=true; //初次绑定编辑曲线信号槽。
|
||||||
|
bool m_bPriviewRightList=false; //当前是否正在预览曲线。
|
||||||
|
|
||||||
QMap<QString, QObject*> m_mapDraggable_Rect;
|
QMap<QString, QObject*> m_mapDraggable_Rect;
|
||||||
QMap<QString, QObject*> m_mapDraggable_Result;
|
QMap<QString, QObject*> m_mapDraggable_Result;
|
||||||
|
|
@ -100,6 +101,7 @@ public:
|
||||||
QMap<QString, QObject*> m_mapDraggable_Jiegutext;
|
QMap<QString, QObject*> m_mapDraggable_Jiegutext;
|
||||||
QMap<QString, QObject*> m_mapDraggable_Line;
|
QMap<QString, QObject*> m_mapDraggable_Line;
|
||||||
QMap<QString, QObject*> m_mapDraggable_SelectRect;
|
QMap<QString, QObject*> m_mapDraggable_SelectRect;
|
||||||
|
QMap<QString, QObject*> m_mapDraggable_RightList;
|
||||||
|
|
||||||
QObject* m_SelectShiftLine=nullptr;//当前选中的分段线
|
QObject* m_SelectShiftLine=nullptr;//当前选中的分段线
|
||||||
QObject* m_SelectRect=nullptr;//当前选中的曲线编辑框
|
QObject* m_SelectRect=nullptr;//当前选中的曲线编辑框
|
||||||
|
|
@ -136,6 +138,9 @@ public:
|
||||||
//框选并编辑曲线
|
//框选并编辑曲线
|
||||||
void addSelectRectToPlot(double left_Low, double right_Hight, int left_Low_Number, int right_Hight_Number);
|
void addSelectRectToPlot(double left_Low, double right_Hight, int left_Low_Number, int right_Hight_Number);
|
||||||
|
|
||||||
|
//预览
|
||||||
|
void addRightListToPlot( QList<double> new_DepthList, QList<double> new_ValueList);
|
||||||
|
|
||||||
public slots:
|
public slots:
|
||||||
void s_LineClicked(int index);
|
void s_LineClicked(int index);
|
||||||
void onResetZoom();
|
void onResetZoom();
|
||||||
|
|
@ -190,6 +195,12 @@ public slots:
|
||||||
//执行拼接
|
//执行拼接
|
||||||
void s_MergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
void s_MergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
|
|
||||||
|
//执行预览
|
||||||
|
void s_PreMergeFromPlot(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
|
void s_PreMerge_FromRightList(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName, QList<double> new_DepthList, QList<double> new_ValueList);
|
||||||
|
//关闭预览框
|
||||||
|
void s_PreMerge_Close(QString strUuid, QString strSlfName, QString strWellName, QString strTrackName, QString strLineName);
|
||||||
|
|
||||||
//Plot重新加载数据
|
//Plot重新加载数据
|
||||||
void s_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName);
|
void s_ReloadPlot(QString strUuid, QString strSlfName, QString strLineName);
|
||||||
|
|
||||||
|
|
|
||||||
491
logPlus/transparentdraggableRightList.cpp
Normal file
491
logPlus/transparentdraggableRightList.cpp
Normal file
|
|
@ -0,0 +1,491 @@
|
||||||
|
#include "transparentdraggableRightList.h"
|
||||||
|
#include "CallManage.h"
|
||||||
|
|
||||||
|
|
||||||
|
extern double g_dPixelPerCm;//每厘米像素数
|
||||||
|
//static GeoIndicatorGenerator m_drawGeo;
|
||||||
|
|
||||||
|
TransparentDraggableRightList::TransparentDraggableRightList(QMyCustomPlot *parentPlot, QString strUuid, double minWidth, QString strTitle)
|
||||||
|
: QObject(parentPlot), mPlot(parentPlot), mstrTitle(strTitle), mMinWidth(minWidth)
|
||||||
|
{
|
||||||
|
m_strUuid = strUuid;
|
||||||
|
//
|
||||||
|
initRect();
|
||||||
|
}
|
||||||
|
|
||||||
|
TransparentDraggableRightList::~TransparentDraggableRightList()
|
||||||
|
{
|
||||||
|
if(mPlot) {
|
||||||
|
// mPlot->removeItem(mRect);
|
||||||
|
// mPlot->removeItem(mLeftHandle);
|
||||||
|
// mPlot->removeItem(mRightHandle);
|
||||||
|
mPlot->m_bPriviewRightList = false;//当前是否正在编辑曲线。
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::DrawSVGNormal(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout)
|
||||||
|
{
|
||||||
|
QString svg=svgFileName;
|
||||||
|
QRectF boundingRect = painter->transform().mapRect(borderRect);
|
||||||
|
painter->save();
|
||||||
|
QTransform transform;
|
||||||
|
transform.reset();
|
||||||
|
if (!IsWellSectonHorizonLayout)
|
||||||
|
{
|
||||||
|
painter->setWorldTransform(transform);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
}
|
||||||
|
QPixmap tiledmap(svg);
|
||||||
|
QRect border(boundingRect.left(),boundingRect.top(),boundingRect.width(),boundingRect.height());
|
||||||
|
painter->drawPixmap(border,tiledmap);
|
||||||
|
painter->restore();
|
||||||
|
}
|
||||||
|
//拉伸
|
||||||
|
void TransparentDraggableRightList::DrawSVGSteched(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout)
|
||||||
|
{
|
||||||
|
QString svg=svgFileName;
|
||||||
|
QSvgRenderer m_SvgRenderer;
|
||||||
|
m_SvgRenderer.load(svg);
|
||||||
|
m_SvgRenderer.render(painter,borderRect);
|
||||||
|
}
|
||||||
|
//平铺
|
||||||
|
void TransparentDraggableRightList::DrawSVGTiled(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout)
|
||||||
|
{
|
||||||
|
QString svg=svgFileName;
|
||||||
|
QRectF boundingRect = painter->transform().mapRect(borderRect);
|
||||||
|
painter->save();
|
||||||
|
QTransform transform;
|
||||||
|
transform.reset();
|
||||||
|
if (!IsWellSectonHorizonLayout)
|
||||||
|
{
|
||||||
|
painter->setWorldTransform(transform);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
}
|
||||||
|
QPixmap tiledmap(svg);
|
||||||
|
painter->drawTiledPixmap(boundingRect,tiledmap);
|
||||||
|
painter->restore();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
//设置最小宽度
|
||||||
|
void TransparentDraggableRightList::setMinWidth(double minWidth)
|
||||||
|
{
|
||||||
|
mMinWidth = minWidth;
|
||||||
|
}
|
||||||
|
|
||||||
|
//设置标题
|
||||||
|
void TransparentDraggableRightList::setTitle(QString strTitle)
|
||||||
|
{
|
||||||
|
mstrTitle = strTitle;
|
||||||
|
mItemTitle->setText(mstrTitle);
|
||||||
|
//mPlot->replot();
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::setRightList(QList<double> new_DepthList, QList<double> new_ValueList)
|
||||||
|
{
|
||||||
|
for (int j=0; j<new_DepthList.size()-1; j++)
|
||||||
|
{
|
||||||
|
QCPItemLine *qcpItemLine = new QCPItemLine(mPlot);
|
||||||
|
qcpItemLine->setPen(QPen(Qt::blue));
|
||||||
|
qcpItemLine->setLayer("overlay"); // 确保在最上层
|
||||||
|
qcpItemLine->start->setCoords(new_DepthList[j], new_ValueList[j]);
|
||||||
|
qcpItemLine->end->setCoords(new_DepthList[j+1], new_ValueList[j+1]);
|
||||||
|
|
||||||
|
//
|
||||||
|
m_qcpItemLine_List.append(qcpItemLine);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// 设置矩形范围
|
||||||
|
void TransparentDraggableRightList::setRange(double left_Low, double right_Hight)
|
||||||
|
{
|
||||||
|
if(left_Low >= right_Hight) return;
|
||||||
|
|
||||||
|
m_left_Low_Current = left_Low;
|
||||||
|
m_right_Hight_Current = right_Hight;
|
||||||
|
//
|
||||||
|
double lY1 = mPlot->yAxis->range().lower;//+10
|
||||||
|
double lY2 = mPlot->yAxis->range().upper;
|
||||||
|
mRect->topLeft->setCoords(left_Low, lY1);
|
||||||
|
mRect->bottomRight->setCoords(right_Hight, lY2);
|
||||||
|
|
||||||
|
double delta = (right_Hight - left_Low) / (double)(m_left_Low_Number-m_right_Hight_Number-1);
|
||||||
|
|
||||||
|
updateHandles();
|
||||||
|
mPlot->replot();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 获取当前范围
|
||||||
|
QCPRange TransparentDraggableRightList::getRange()
|
||||||
|
{
|
||||||
|
return QCPRange(mRect->topLeft->coords().x(), mRect->bottomRight->coords().x());
|
||||||
|
}
|
||||||
|
|
||||||
|
// 设置矩形颜色
|
||||||
|
void TransparentDraggableRightList::setColor(const QColor &color)
|
||||||
|
{
|
||||||
|
mRect->setBrush(QBrush(color));
|
||||||
|
mRect->setPen(QPen(color.darker()));
|
||||||
|
//mPlot->replot();
|
||||||
|
}
|
||||||
|
|
||||||
|
// 删除框图
|
||||||
|
void TransparentDraggableRightList::deleteRect()
|
||||||
|
{
|
||||||
|
if(mPlot) {
|
||||||
|
|
||||||
|
// mRect->deleteLater();
|
||||||
|
// mLeftHandle->deleteLater();
|
||||||
|
// mRightHandle->deleteLater();
|
||||||
|
// mPixmap->deleteLater();
|
||||||
|
|
||||||
|
mPlot->m_mapDraggable_RightList.remove(m_strUuid);
|
||||||
|
|
||||||
|
mPlot->removeItem(mRect);
|
||||||
|
mPlot->removeItem(mLeftHandle);
|
||||||
|
mPlot->removeItem(mRightHandle);
|
||||||
|
mPlot->removeItem(mPixmap);
|
||||||
|
mPlot->removeItem(mItemTitle);
|
||||||
|
|
||||||
|
for(int i=m_qcpItemLine_List.size()-1; i>-1; i--)
|
||||||
|
{
|
||||||
|
mPlot->removeItem(m_qcpItemLine_List[i]);
|
||||||
|
}
|
||||||
|
mPlot->m_bPriviewRightList = false;//当前是否正在编辑曲线。
|
||||||
|
|
||||||
|
mPlot->replot();
|
||||||
|
this->deleteLater();
|
||||||
|
|
||||||
|
//
|
||||||
|
// //避免二次绘制框图
|
||||||
|
// mPlot->m_bDrawRect = false;
|
||||||
|
// mDragMode = DragNone;
|
||||||
|
// //取消选中框
|
||||||
|
// mPlot->selectionRect()->cancel();
|
||||||
|
// mPlot->replot();
|
||||||
|
// mPlot->selectionRect()->mActive=true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::initRect()
|
||||||
|
{
|
||||||
|
// 创建透明矩形
|
||||||
|
mRect = new QCPItemRect(mPlot);
|
||||||
|
mRect->setLayer("overlay"); // 确保在最上层
|
||||||
|
mRect->setBrush(QBrush(QColor(255, 255, 255, 50))); // 半透明蓝色
|
||||||
|
mRect->setPen(QPen(QColor(70, 70, 255, 200)));
|
||||||
|
|
||||||
|
// 创建左右边界控制点
|
||||||
|
mLeftHandle = new QCPItemRect(mPlot);
|
||||||
|
mLeftHandle->setLayer("overlay");
|
||||||
|
mLeftHandle->setBrush(QBrush(Qt::red));
|
||||||
|
mLeftHandle->setPen(QPen(Qt::darkRed));
|
||||||
|
|
||||||
|
mRightHandle = new QCPItemRect(mPlot);
|
||||||
|
mRightHandle->setLayer("overlay");
|
||||||
|
mRightHandle->setBrush(QBrush(Qt::red));
|
||||||
|
mRightHandle->setPen(QPen(Qt::darkRed));
|
||||||
|
|
||||||
|
// 设置初始位置
|
||||||
|
//double center = mPlot->xAxis->range().center();
|
||||||
|
// setRange(center - 10, center + 10);
|
||||||
|
|
||||||
|
// 连接鼠标事件
|
||||||
|
connect(mPlot, &QCustomPlot::mousePress, this, &TransparentDraggableRightList::onMousePress);
|
||||||
|
//connect(mPlot, &QCustomPlot::mouseMove, this, &TransparentDraggableRightList::onMouseMove);
|
||||||
|
connect(mPlot, &QCustomPlot::mouseRelease, this, &TransparentDraggableRightList::onMouseRelease);
|
||||||
|
|
||||||
|
mPixmap = new QCPItemPixmap(mPlot);
|
||||||
|
//mPixmap->setPixmap(QPixmap(":/image/file.png")); // 设置图片
|
||||||
|
mPixmap->setScaled(true, Qt::IgnoreAspectRatio); // 设置缩放方式
|
||||||
|
mPixmap->setLayer("overlay"); // 确保在最上层
|
||||||
|
|
||||||
|
mItemTitle = new QCPItemText(mPlot);
|
||||||
|
mItemTitle->setText(mstrTitle);
|
||||||
|
//mItemTitle->setBrush(QBrush(Qt::red));
|
||||||
|
mItemTitle->setFont(QFont("Arial", 12, QFont::Bold));
|
||||||
|
mItemTitle->setColor(Qt::black);
|
||||||
|
mItemTitle->setPositionAlignment(Qt::AlignTop | Qt::AlignHCenter);
|
||||||
|
mItemTitle->position->setType(QCPItemPosition::ptPlotCoords);
|
||||||
|
//mItemTitle->position->setType(QCPItemPosition::ptAxisRectRatio);
|
||||||
|
mItemTitle->position->setCoords(0.5, 0);
|
||||||
|
mItemTitle->setLayer("overlay");
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::updateHandles()
|
||||||
|
{
|
||||||
|
// 左边界矩形控制点
|
||||||
|
mLeftHandle->topLeft->setParentAnchor(mRect->topLeft);
|
||||||
|
mLeftHandle->bottomRight->setParentAnchor(mRect->topRight);//(mRect->bottomLeft);
|
||||||
|
mLeftHandle->topLeft->setCoords(-0.5, 0.5); // 矩形大小
|
||||||
|
mLeftHandle->bottomRight->setCoords(0.5, -0.5); // 矩形大小
|
||||||
|
|
||||||
|
// 右边界矩形控制点
|
||||||
|
mRightHandle->topLeft->setParentAnchor(mRect->bottomLeft);
|
||||||
|
mRightHandle->bottomRight->setParentAnchor(mRect->bottomRight);
|
||||||
|
mRightHandle->topLeft->setCoords(-0.5, 0.5); // 矩形大小
|
||||||
|
mRightHandle->bottomRight->setCoords(0.5, -0.5); // 矩形大小
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::slotSaveChange()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::onDelRect()
|
||||||
|
{
|
||||||
|
//mDragMode = DragNone;
|
||||||
|
//删除框图
|
||||||
|
deleteRect();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::onMousePress(QMouseEvent *event)
|
||||||
|
{
|
||||||
|
if(event->button() != Qt::LeftButton)//右键
|
||||||
|
{
|
||||||
|
double y = mPlot->xAxis->pixelToCoord(event->pos().y());//x轴展示深度
|
||||||
|
QCPRange currentRange = getRange();
|
||||||
|
if(mLeftHandle->selectTest(event->pos(), false) < 5) {
|
||||||
|
mDragMode = DragNone;
|
||||||
|
}
|
||||||
|
else if(mRightHandle->selectTest(event->pos(), false) < 5) {
|
||||||
|
mDragMode = DragNone;
|
||||||
|
}
|
||||||
|
//else if(x >= currentRange.lower && x <= currentRange.upper) {
|
||||||
|
else if(y >= currentRange.lower && y <= currentRange.upper) {
|
||||||
|
mDragMode = DragNone;
|
||||||
|
|
||||||
|
QMenu menu(mPlot);
|
||||||
|
//menu.addAction(QIcon(::GetImagePath() + "icon/savecurve.png"), "保存当前数据修改", this, &TransparentDraggableRightList::slotSaveChange);
|
||||||
|
menu.addAction(QIcon(::GetImagePath() + "icon/ClearSel.png"), "放弃当前数据修改", this, &TransparentDraggableRightList::onDelRect);
|
||||||
|
menu.exec(event->globalPos());
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
mDragMode = DragNone;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//event->accept();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//不处理事件-----------------------
|
||||||
|
return;
|
||||||
|
|
||||||
|
event->accept();
|
||||||
|
|
||||||
|
// 检查点击了哪个部分
|
||||||
|
//double x = mPlot->xAxis->pixelToCoord(event->pos().x());
|
||||||
|
//double y = mPlot->yAxis->pixelToCoord(event->pos().y());
|
||||||
|
|
||||||
|
double y = mPlot->xAxis->pixelToCoord(event->pos().y());//x轴展示深度
|
||||||
|
|
||||||
|
QCPRange currentRange = getRange();
|
||||||
|
|
||||||
|
if(mLeftHandle->selectTest(event->pos(), false) < 5) {
|
||||||
|
mDragMode = DragLeft;
|
||||||
|
}
|
||||||
|
else if(mRightHandle->selectTest(event->pos(), false) < 5) {
|
||||||
|
mDragMode = DragRight;
|
||||||
|
}
|
||||||
|
//else if(x >= currentRange.lower && x <= currentRange.upper) {
|
||||||
|
else if(y >= currentRange.lower && y <= currentRange.upper) {
|
||||||
|
mDragMode = DragRect;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
mDragMode = DragNone;
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
//mDragStartX = x;
|
||||||
|
mDragStartY = y;
|
||||||
|
mDragStartRange = currentRange;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::onMouseMove(QMouseEvent *event)
|
||||||
|
{
|
||||||
|
if(mDragMode == DragNone) return;
|
||||||
|
|
||||||
|
event->accept();
|
||||||
|
|
||||||
|
//double x = mPlot->xAxis->pixelToCoord(event->pos().x());
|
||||||
|
//double dx = x - mDragStartX;
|
||||||
|
|
||||||
|
double y = mPlot->xAxis->pixelToCoord(event->pos().y());
|
||||||
|
double dy = y - mDragStartY;
|
||||||
|
|
||||||
|
QCPRange newRange = mDragStartRange;
|
||||||
|
|
||||||
|
switch(mDragMode) {
|
||||||
|
case DragLeft: {
|
||||||
|
//double proposedLeft = mDragStartRange.lower + dx;
|
||||||
|
double proposedLeft = mDragStartRange.lower + dy;
|
||||||
|
// 确保不超出轴范围且不使宽度小于最小值
|
||||||
|
newRange.lower = qBound(
|
||||||
|
//mPlot->xAxis->range().lower,
|
||||||
|
getMyLower(),
|
||||||
|
proposedLeft,
|
||||||
|
mDragStartRange.upper - mMinWidth);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case DragRight: {
|
||||||
|
//double proposedRight = mDragStartRange.upper + dx;
|
||||||
|
double proposedRight = mDragStartRange.upper + dy;
|
||||||
|
// 确保不超出轴范围且不使宽度小于最小值
|
||||||
|
newRange.upper = qBound(
|
||||||
|
mDragStartRange.lower + mMinWidth,
|
||||||
|
proposedRight,
|
||||||
|
getMyUpper());
|
||||||
|
//mPlot->xAxis->range().upper);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case DragRect: {
|
||||||
|
double width = mDragStartRange.size();
|
||||||
|
//double center = mDragStartRange.center() + dx;
|
||||||
|
double center = mDragStartRange.center() + dy;
|
||||||
|
newRange.lower = center - width/2;
|
||||||
|
newRange.upper = center + width/2;
|
||||||
|
|
||||||
|
// 检查是否超出轴范围
|
||||||
|
if(newRange.lower < getMyLower()) {
|
||||||
|
newRange.lower = getMyLower();
|
||||||
|
newRange.upper = newRange.lower + width;
|
||||||
|
}
|
||||||
|
else if(newRange.upper > getMyUpper()) {
|
||||||
|
newRange.upper = getMyUpper();
|
||||||
|
newRange.lower = newRange.upper - width;
|
||||||
|
}
|
||||||
|
|
||||||
|
// QCPRange axisRange = mPlot->xAxis->range();
|
||||||
|
// if(newRange.lower < axisRange.lower) {
|
||||||
|
// newRange.lower = axisRange.lower;
|
||||||
|
// newRange.upper = newRange.lower + width;
|
||||||
|
// }
|
||||||
|
// else if(newRange.upper > axisRange.upper) {
|
||||||
|
// newRange.upper = axisRange.upper;
|
||||||
|
// newRange.lower = newRange.upper - width;
|
||||||
|
// }
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default:
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
|
// //取整数(方便显示统计,左右边界整数显示。)
|
||||||
|
// newRange.lower = (int)newRange.lower;
|
||||||
|
// QCPRange rangeByFile = mPlot->xAxis->range();
|
||||||
|
// if (std::fabs(rangeByFile.upper - (int)newRange.upper) >= 1.0)
|
||||||
|
// {
|
||||||
|
// newRange.upper = (int)newRange.upper;
|
||||||
|
// }
|
||||||
|
|
||||||
|
// 最终确保宽度不小于最小值(针对整体拖动的情况)
|
||||||
|
if(newRange.size() < mMinWidth) {
|
||||||
|
if(mDragMode == DragRect) {
|
||||||
|
// 如果是整体拖动,保持中心点不变
|
||||||
|
double center = newRange.center();
|
||||||
|
newRange.lower = center - mMinWidth/2;
|
||||||
|
newRange.upper = center + mMinWidth/2;
|
||||||
|
} else {
|
||||||
|
// 如果是边界拖动,强制设置最小宽度
|
||||||
|
if(mDragMode == DragLeft) {
|
||||||
|
newRange.lower = newRange.upper - mMinWidth;
|
||||||
|
} else if(mDragMode == DragRight) {
|
||||||
|
newRange.upper = newRange.lower + mMinWidth;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
setRange(newRange.lower, newRange.upper);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
void TransparentDraggableRightList::onMouseRelease(QMouseEvent *event)
|
||||||
|
{
|
||||||
|
//不处理事件-----------------------
|
||||||
|
return;
|
||||||
|
|
||||||
|
if(event->button() == Qt::LeftButton && mDragMode != DragNone) {
|
||||||
|
event->accept();
|
||||||
|
//避免二次绘制框图
|
||||||
|
mPlot->m_bDrawRect = false;
|
||||||
|
//emit rangeChanged(getRange());
|
||||||
|
mDragMode = DragNone;
|
||||||
|
//取消选中状态
|
||||||
|
// QCPDataSelection emptySelection;
|
||||||
|
// mPlot->graph(0)->setSelection(emptySelection);
|
||||||
|
// mPlot->replot();
|
||||||
|
|
||||||
|
//取消选中框
|
||||||
|
mPlot->selectionRect()->cancel();
|
||||||
|
mPlot->replot();
|
||||||
|
mPlot->selectionRect()->mActive=true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
double TransparentDraggableRightList::getMyLower()
|
||||||
|
{
|
||||||
|
double dLower = mPlot->xAxis->range().lower;
|
||||||
|
double proposedLeft = mDragStartRange.lower;
|
||||||
|
|
||||||
|
TransparentDraggableRightList *pDraggableRect =NULL;
|
||||||
|
{
|
||||||
|
QMap<QString,QObject *>::Iterator it = mPlot->m_mapDraggable_RightList.begin();
|
||||||
|
while( it != mPlot->m_mapDraggable_RightList.end() )
|
||||||
|
{
|
||||||
|
if(it.key() == m_strUuid)
|
||||||
|
{
|
||||||
|
it++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
pDraggableRect = (TransparentDraggableRightList*)it.value();
|
||||||
|
//
|
||||||
|
QCPRange tmpRange = pDraggableRect->getRange();
|
||||||
|
if(tmpRange.upper >= dLower && tmpRange.upper <= proposedLeft)
|
||||||
|
{
|
||||||
|
dLower = tmpRange.upper;
|
||||||
|
}
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return dLower;
|
||||||
|
}
|
||||||
|
|
||||||
|
double TransparentDraggableRightList::getMyUpper()
|
||||||
|
{
|
||||||
|
double dUpper = mPlot->xAxis->range().upper;
|
||||||
|
double proposedRight = mDragStartRange.upper;
|
||||||
|
|
||||||
|
TransparentDraggableRightList *pDraggableRect =NULL;
|
||||||
|
{
|
||||||
|
QMap<QString,QObject *>::Iterator it = mPlot->m_mapDraggable_RightList.begin();
|
||||||
|
while( it != mPlot->m_mapDraggable_RightList.end() )
|
||||||
|
{
|
||||||
|
if(it.key() == m_strUuid)
|
||||||
|
{
|
||||||
|
it++;
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
pDraggableRect = (TransparentDraggableRightList*)it.value();
|
||||||
|
//
|
||||||
|
QCPRange tmpRange = pDraggableRect->getRange();
|
||||||
|
if(tmpRange.lower <= dUpper && tmpRange.lower >= proposedRight)
|
||||||
|
{
|
||||||
|
dUpper = tmpRange.lower;
|
||||||
|
}
|
||||||
|
it++;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return dUpper;
|
||||||
|
}
|
||||||
91
logPlus/transparentdraggableRightList.h
Normal file
91
logPlus/transparentdraggableRightList.h
Normal file
|
|
@ -0,0 +1,91 @@
|
||||||
|
#ifndef TRANSPARENTDRAGGABLERIGHTLIST_H
|
||||||
|
#define TRANSPARENTDRAGGABLERIGHTLIST_H
|
||||||
|
|
||||||
|
#include <QObject>
|
||||||
|
#include "qmycustomplot.h"
|
||||||
|
#include <QString>
|
||||||
|
#include <QMenu>
|
||||||
|
#include "geometryutils.h"
|
||||||
|
#include <QSvgRenderer>
|
||||||
|
|
||||||
|
#pragma execution_character_set("utf-8") // 强制指定执行字符集为 UTF-8
|
||||||
|
|
||||||
|
class TransparentDraggableRightList : public QObject
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
public:
|
||||||
|
explicit TransparentDraggableRightList(QMyCustomPlot *parentPlot, QString strUuid="", double minWidth = 1.0, QString strTitle = "");
|
||||||
|
|
||||||
|
|
||||||
|
~TransparentDraggableRightList();
|
||||||
|
|
||||||
|
|
||||||
|
void DrawSVGNormal(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout);
|
||||||
|
//拉伸
|
||||||
|
void DrawSVGSteched(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout);
|
||||||
|
//平铺
|
||||||
|
void DrawSVGTiled(QPainter* painter,QString svgFileName,QRectF borderRect,bool IsWellSectonHorizonLayout);
|
||||||
|
//设置最小宽度
|
||||||
|
void setMinWidth(double minWidth);
|
||||||
|
//设置标题
|
||||||
|
void setTitle(QString strTitle);
|
||||||
|
|
||||||
|
void setRightList(QList<double> new_DepthList, QList<double> new_ValueList);
|
||||||
|
|
||||||
|
// 设置矩形范围
|
||||||
|
void setRange(double left_Low, double right_Hight);
|
||||||
|
// 获取当前范围
|
||||||
|
QCPRange getRange();
|
||||||
|
|
||||||
|
// 设置矩形颜色
|
||||||
|
void setColor(const QColor &color);
|
||||||
|
|
||||||
|
// 删除框图
|
||||||
|
void deleteRect();
|
||||||
|
|
||||||
|
signals:
|
||||||
|
void rangeChanged(QCPRange newRange);
|
||||||
|
void sig_DelRect();
|
||||||
|
|
||||||
|
private:
|
||||||
|
void initRect();
|
||||||
|
void updateHandles() ;
|
||||||
|
|
||||||
|
private slots:
|
||||||
|
void slotSaveChange();
|
||||||
|
void onDelRect();
|
||||||
|
void onMousePress(QMouseEvent *event);
|
||||||
|
void onMouseMove(QMouseEvent *event);
|
||||||
|
void onMouseRelease(QMouseEvent *event);
|
||||||
|
double getMyLower();
|
||||||
|
double getMyUpper();
|
||||||
|
|
||||||
|
private:
|
||||||
|
QMyCustomPlot *mPlot;
|
||||||
|
QCPItemRect *mRect;
|
||||||
|
QCPItemRect *mLeftHandle;
|
||||||
|
QCPItemRect *mRightHandle;
|
||||||
|
|
||||||
|
QCPItemPixmap *mPixmap;
|
||||||
|
QCPItemText *mItemTitle;
|
||||||
|
QString mstrTitle="";
|
||||||
|
QString m_strUuid = "";
|
||||||
|
QString m_Result;
|
||||||
|
//
|
||||||
|
QList<QCPItemLine*> m_qcpItemLine_List;
|
||||||
|
int m_left_Low_Number;
|
||||||
|
int m_right_Hight_Number;
|
||||||
|
double m_left_Low_Current;
|
||||||
|
double m_right_Hight_Current;
|
||||||
|
|
||||||
|
enum DragMode { DragNone, DragLeft, DragRight, DragRect };
|
||||||
|
DragMode mDragMode = DragNone;
|
||||||
|
//double mDragStartX = 0;
|
||||||
|
double mDragStartY = 0;
|
||||||
|
QCPRange mDragStartRange;
|
||||||
|
|
||||||
|
// 添加最小宽度成员变量
|
||||||
|
double mMinWidth;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // TRANSPARENTDRAGGABLERIGHTLIST_H
|
||||||
|
|
@ -105,90 +105,6 @@ void TransparentDraggableSelectRect::setNumber(int left_Low_Number, int right_Hi
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//设置解释结论
|
|
||||||
void TransparentDraggableSelectRect::setResult(QString filePath)
|
|
||||||
{
|
|
||||||
m_Result = filePath;
|
|
||||||
}
|
|
||||||
|
|
||||||
void TransparentDraggableSelectRect::drawResult(double left_Low, double right_Hight, double lY1, double lY2)
|
|
||||||
{
|
|
||||||
if(m_Result=="")
|
|
||||||
{
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
double x1 = mPlot->xAxis->coordToPixel(left_Low);
|
|
||||||
double x2 = mPlot->xAxis->coordToPixel(right_Hight);
|
|
||||||
double y1 = mPlot->yAxis->coordToPixel(lY1);
|
|
||||||
double y2 = mPlot->yAxis->coordToPixel(lY2);
|
|
||||||
|
|
||||||
//
|
|
||||||
QString filePath = m_Result;
|
|
||||||
//
|
|
||||||
QString strLast = filePath.right(4);
|
|
||||||
if(strLast.toLower()==".svg")
|
|
||||||
{
|
|
||||||
QString path,filename;
|
|
||||||
GetWellNameAndPath(filePath, filename, path);
|
|
||||||
QString basename = filename;
|
|
||||||
|
|
||||||
QString val=filePath;
|
|
||||||
QImage image(y2-y1, x1-x2,QImage::Format_RGB32);
|
|
||||||
QPainter painter(&image);
|
|
||||||
QRectF fillRect(0,0, y2-y1, x1-x2);
|
|
||||||
painter.fillRect(fillRect,Qt::white);
|
|
||||||
//拉伸
|
|
||||||
DrawSVGSteched(&painter,filePath,fillRect,0);
|
|
||||||
//平铺
|
|
||||||
//DrawSVGTiled(&painter,filePath,fillRect,0);
|
|
||||||
//正常
|
|
||||||
//DrawSVGNormal(&painter,filePath,fillRect,0);
|
|
||||||
|
|
||||||
val=GetImagePath()+"TempNew";
|
|
||||||
QDir ss;
|
|
||||||
if(!ss.exists(val)) {
|
|
||||||
ss.mkdir(val);
|
|
||||||
}
|
|
||||||
val+=QDir::separator();
|
|
||||||
val+=basename+".png";
|
|
||||||
image.save(val);
|
|
||||||
|
|
||||||
//
|
|
||||||
mPixmap->setPixmap(QPixmap(val)); // 设置图片
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
mPixmap->setPixmap(QPixmap(filePath)); // 设置图片
|
|
||||||
|
|
||||||
// QString path,filename;
|
|
||||||
// GetWellNameAndPath(filePath, filename, path);
|
|
||||||
// QString basename = filename;
|
|
||||||
|
|
||||||
// QString val=filePath;
|
|
||||||
// QImage image(y2-y1, x1-x2,QImage::Format_RGB32);
|
|
||||||
// QPainter painter(&image);
|
|
||||||
// QRectF fillRect(0,0, y2-y1, x1-x2);
|
|
||||||
// painter.fillRect(fillRect,Qt::white);
|
|
||||||
// //平铺
|
|
||||||
// DrawSVGNormal(&painter,filePath,fillRect,0);
|
|
||||||
|
|
||||||
// val=GetImagePath()+"TempNew";
|
|
||||||
// QDir ss;
|
|
||||||
// if(!ss.exists(val)) {
|
|
||||||
// ss.mkdir(val);
|
|
||||||
// }
|
|
||||||
// val+=QDir::separator();
|
|
||||||
// val+=basename+".png";
|
|
||||||
// image.save(val);
|
|
||||||
|
|
||||||
// //
|
|
||||||
// mPixmap->setPixmap(QPixmap(val)); // 设置图片
|
|
||||||
}
|
|
||||||
|
|
||||||
//mPlot->replot();
|
|
||||||
}
|
|
||||||
|
|
||||||
// 设置矩形范围
|
// 设置矩形范围
|
||||||
void TransparentDraggableSelectRect::setRange(double left_Low, double right_Hight)
|
void TransparentDraggableSelectRect::setRange(double left_Low, double right_Hight)
|
||||||
{
|
{
|
||||||
|
|
@ -213,20 +129,6 @@ void TransparentDraggableSelectRect::setRange(double left_Low, double right_High
|
||||||
iLoop++;
|
iLoop++;
|
||||||
}
|
}
|
||||||
|
|
||||||
//位置与rect不一样,否则图像反转
|
|
||||||
// mPixmap->topLeft->setCoords(right_Hight, lY1);
|
|
||||||
// mPixmap->bottomRight->setCoords(left_Low, lY2);
|
|
||||||
//drawResult(left_Low, right_Hight, lY1, lY2);
|
|
||||||
|
|
||||||
//mItemTitle->position->setCoords(0.5, 0.5);
|
|
||||||
// 设置父锚点,定位点
|
|
||||||
//mItemTitle->position->setParentAnchor(mRect->bottom);
|
|
||||||
// mItemTitle->position->setCoords((mRect->topLeft->coords().x() + mRect->bottomRight->coords().x())/2,
|
|
||||||
// (mRect->topLeft->coords().y() + mRect->bottomRight->coords().y())/2); // 设置文本在矩形中心位置
|
|
||||||
|
|
||||||
//mRect->topLeft->setCoords(left, mPlot->yAxis->range().upper);
|
|
||||||
//mRect->bottomRight->setCoords(right, mPlot->yAxis->range().lower);
|
|
||||||
|
|
||||||
updateHandles();
|
updateHandles();
|
||||||
mPlot->replot();
|
mPlot->replot();
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -32,10 +32,6 @@ public:
|
||||||
|
|
||||||
void setNumber(int left_Low_Number, int right_Hight_Number);
|
void setNumber(int left_Low_Number, int right_Hight_Number);
|
||||||
|
|
||||||
//设置解释结论
|
|
||||||
void setResult(QString filePath);
|
|
||||||
void drawResult(double left_Low, double right_Hight, double lY1, double lY2);
|
|
||||||
|
|
||||||
// 设置矩形范围
|
// 设置矩形范围
|
||||||
void setRange(double left_Low, double right_Hight);
|
void setRange(double left_Low, double right_Hight);
|
||||||
// 获取当前范围
|
// 获取当前范围
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user