From ce3793790d007a89ccfa483fdb802bf5f778a4c1 Mon Sep 17 00:00:00 2001
From: LAPTOP-T815PCOQ\25526 <mr.liuyang@126.com>
Date: 星期二, 10 十二月 2024 11:29:03 +0800
Subject: [PATCH] 1.配方管理类中定位点添加标识符 2.axis设定读取不可写的定位点数据,并且刷新 3. 完善axis细部设定界面资源
---
SourceCode/Bond/BondEq/View/UserManagerDlg.cpp | 21 ++++-----------------
1 files changed, 4 insertions(+), 17 deletions(-)
diff --git a/SourceCode/Bond/BondEq/View/UserManagerDlg.cpp b/SourceCode/Bond/BondEq/View/UserManagerDlg.cpp
index 9daa3d1..849c4a9 100644
--- a/SourceCode/Bond/BondEq/View/UserManagerDlg.cpp
+++ b/SourceCode/Bond/BondEq/View/UserManagerDlg.cpp
@@ -119,7 +119,7 @@
int nCurrNameRow = -1;
std::vector<std::vector<std::string>> usersData = userManager.getUsers();
if (!usersData.empty()) {
- m_gridUserManager.SetRowCount(usersData.size() + 1);
+ m_gridUserManager.SetRowCount((int)usersData.size() + 1);
for (int i = 0; i < usersData.size(); i++) {
int nRowIdx = i + 1;
@@ -440,23 +440,10 @@
int fontSize = nHeight / 2;
if (fontSize < 8) fontSize = 8;
- // 妫�鏌ュ瓧浣撴槸鍚﹀凡缁忓瓨鍦�
- auto it = m_mapFonts.find(fontSize);
- if (it == m_mapFonts.end()) {
- // 鍔ㄦ�佸垱寤烘柊瀛椾綋
- CFont* newFont = new CFont();
- LOGFONT logFont = { 0 };
- _tcscpy_s(logFont.lfFaceName, _T("Segoe UI"));
- logFont.lfHeight = -fontSize;
- logFont.lfQuality = CLEARTYPE_QUALITY; // 鍚敤 ClearType 鎶楅敮榻�
- newFont->CreateFontIndirect(&logFont);
+ // 鑾峰彇鎴栧垱寤哄瓧浣�
+ CFont* pFont = GetOrCreateFont(fontSize);
- // 瀛樺偍鍒板瓧浣撶鐞嗗鍣ㄤ腑
- m_mapFonts[fontSize] = newFont;
- it = m_mapFonts.find(fontSize);
- }
-
- pWnd->SetFont(it->second);
+ pWnd->SetFont(pFont);
pWnd->Invalidate(); // 鍒锋柊鎺т欢鏄剧ず
}
--
Gitblit v1.9.3