tx
2025-04-22 e0b138b3e057de6f57021e6c8963868f5c5acc5a
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing.Drawing2D;
using System.Drawing;
using Eventech.Utils.Images;
 
namespace TProduct.PumpGraph.Picture
{
    public class FeatTextPosiInfo
    {
        public long ID { get; set; }
        public double Q { get; set; }
        public double H { get; set; }
        public string Content { get; set; }
    }
    public partial class LxpSeriesChart
    {
        protected List<FeatTextPosiInfo> _pumpCurveNameList = null;//曲线名称
        //设置名称位置
        public void SetPumpCurveNamePosi(List<FeatTextPosiInfo> list)
        {
            _pumpCurveNameList = list;
        }
        protected float _curveNameLabelTextSize = 10;
        protected Color _curveNameLabelTextColor = Color.DarkBlue;
        protected List<Eventech.Model.FeatPointString> _curveNameLabelPosiList = null;
        public List<Eventech.Model.FeatPointString> CurveNameLabelPosiList { get { return _curveNameLabelPosiList; } set { _curveNameLabelPosiList = value; } }
 
        protected void DrawCurveNames()
        {
            if (_curveNameLabelPosiList != null)
            {
                using (var fontText = new System.Drawing.Font("Arial", _curveNameLabelTextSize, System.Drawing.FontStyle.Regular))
                using (SolidBrush drawBrush = new SolidBrush(_curveNameLabelTextColor))
                {
                    foreach (var label in _curveNameLabelPosiList)
                    {
                        _graphics.DrawString(label.StringValue,fontText, drawBrush,  MapRealToPictQ(label.X ), MapRealToPictH(label.Y));
                    }
                }
            }
        }
 
 
    }
}