From 3685398d0168ce532f7a84e498dd4fadc10c0fa7 Mon Sep 17 00:00:00 2001 From: crqiqi77 Date: Tue, 31 Mar 2026 16:24:45 +0800 Subject: [PATCH] =?UTF-8?q?=E9=A2=91=E7=8E=87=E7=BB=9F=E8=AE=A1=E5=9B=BE?= =?UTF-8?q?=E5=B1=9E=E6=80=A7=20yxzpdialog=E4=BF=AE=E6=94=B9=E6=96=87?= =?UTF-8?q?=E4=BB=B6=E7=BC=96=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- logPlus/PropertyWidget.cpp | 15 ++++++++++++--- logPlus/PropertyWidget.h | 2 +- logPlus/YxzpDialog.cpp | 2 +- logPlus/YxzpDialog.h | 6 +++--- 4 files changed, 17 insertions(+), 8 deletions(-) diff --git a/logPlus/PropertyWidget.cpp b/logPlus/PropertyWidget.cpp index 4999894..3663296 100644 --- a/logPlus/PropertyWidget.cpp +++ b/logPlus/PropertyWidget.cpp @@ -2282,7 +2282,11 @@ void PropertyWidget::SlotPropertyChanged( QtProperty *pProperty, const QVariant m_item->setFont(newFont); } } - + else if(m_strCurrentProperty == PL_OBJECT_PROPERTY) // 频率统计图 + { + CommonPropertyChanged(pProperty, variant); + changedPlObjectProperty(m_propertyData[pProperty], variant); + } @@ -4106,9 +4110,14 @@ void PropertyWidget::initPlObjectProperty(FormInfo *formInfo) _CreateVariantPropertyItem("分类", "自定义2", formInfo->m_strAliasName, QVariant::String); } -void PropertyWidget::changedPlObjectProperty(QString strProName, QVariant val) +void PropertyWidget::changedPlObjectProperty(QString strProperty, QVariant varVal) { - + if ("名称" == strProperty) + { + QFont newFont = varVal.value(); + m_formInfo->m_curveNameFont = newFont; + this->m_formInfo->repaint(); + } } void PropertyWidget::changedDepthProperty(QString strProperty, QVariant varVal) diff --git a/logPlus/PropertyWidget.h b/logPlus/PropertyWidget.h index c77f357..d18ee43 100644 --- a/logPlus/PropertyWidget.h +++ b/logPlus/PropertyWidget.h @@ -52,7 +52,7 @@ #define CORE_PHYSICS_ITEM_PROPERTY "CORE_PHYSICS_ITEM_PROPERTY" // 岩心分析item #define Depth_Property "Depth_Property" // 深度 -#define PL_OBJECT_PROPERTY "PL_OBJECT_PROPERTY" // 深度 +#define PL_OBJECT_PROPERTY "PL_OBJECT_PROPERTY" // 频率统计图 #define SwallCore_Property "SwallCore_Property" //井壁取心 #define SwallCoreItem_Property "SwallCoreItem_Property" //井壁取心item diff --git a/logPlus/YxzpDialog.cpp b/logPlus/YxzpDialog.cpp index 9909dd6..cf2ab9f 100644 --- a/logPlus/YxzpDialog.cpp +++ b/logPlus/YxzpDialog.cpp @@ -1,4 +1,4 @@ -#include "YxzpDialog.h" +#include "YxzpDialog.h" YxzpDialog::YxzpDialog(QWidget *parent) : QDialog(parent) diff --git a/logPlus/YxzpDialog.h b/logPlus/YxzpDialog.h index 6402322..841e761 100644 --- a/logPlus/YxzpDialog.h +++ b/logPlus/YxzpDialog.h @@ -1,4 +1,4 @@ -#ifndef YXZPDIALOG_H +#ifndef YXZPDIALOG_H #define YXZPDIALOG_H // 岩心照片 自定义 dialog #include @@ -8,10 +8,10 @@ #include #include #include - - #include +#pragma execution_character_set("utf-8") + class YxzpDialog : public QDialog { Q_OBJECT