프로젝트

일반

사용자정보

개정판 13a36357

ID13a36357b60bfece222a14fe58758dade3400cb3
상위 692f6b3b
하위 f0202f86

백흠경이(가) 일년 이상 전에 추가함

Feature: Compare용 프로그램 작성

Change-Id: I1fca10146c658109d10497667de05a90c93c8f7e

차이점 보기:

ID2.Manager/ID2.Manager.Common/ID2.Manager.Common.csproj
49 49
    <LangVersion>7.3</LangVersion>
50 50
    <ErrorReport>prompt</ErrorReport>
51 51
  </PropertyGroup>
52
  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x86'">
53
    <DebugSymbols>true</DebugSymbols>
54
    <OutputPath>bin\x86\Debug\</OutputPath>
55
    <DefineConstants>DEBUG;TRACE</DefineConstants>
56
    <DebugType>full</DebugType>
57
    <PlatformTarget>x86</PlatformTarget>
58
    <LangVersion>7.3</LangVersion>
59
    <ErrorReport>prompt</ErrorReport>
60
  </PropertyGroup>
61
  <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x86'">
62
    <OutputPath>bin\x86\Release\</OutputPath>
63
    <DefineConstants>TRACE</DefineConstants>
64
    <Optimize>true</Optimize>
65
    <DebugType>pdbonly</DebugType>
66
    <PlatformTarget>x86</PlatformTarget>
67
    <LangVersion>7.3</LangVersion>
68
    <ErrorReport>prompt</ErrorReport>
69
  </PropertyGroup>
52 70
  <ItemGroup>
53 71
    <Reference Include="System" />
54 72
    <Reference Include="System.Configuration" />
ID2.Manager/ID2.Manager.Compare/App.Debug.config
1
<?xml version="1.0"?>
2
<!-- For more information on using app.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
3
<!-- In case configuration is not the root element, replace it with root element in source configuration file -->
4
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
5
</configuration>
ID2.Manager/ID2.Manager.Compare/App.Release.config
1
<?xml version="1.0"?>
2
<!-- For more information on using app.config transformation visit http://go.microsoft.com/fwlink/?LinkId=125889 -->
3
<!-- In case configuration is not the root element, replace it with root element in source configuration file -->
4
<configuration xmlns:xdt="http://schemas.microsoft.com/XML-Document-Transform">
5
	<connectionStrings xdt:Transform="Replace">
6
		<add name="ID2Manager" providerName="System.Data.SqlClient" connectionString="data source=12.127.163.230,10102;initial catalog=ID2Manager;persist security info=True;user id=sa;password=P@sswd12;multipleactiveresultsets=True" />
7
		<add name="Markus" providerName="System.Data.SqlClient" connectionString="data source=12.127.163.230,10102;initial catalog=Markus_SEC;persist security info=True;user id=sa;password=P@sswd12;multipleactiveresultsets=True" />
8
		<add name="ID2Project" providerName="System.Data.SqlClient" connectionString="data source={0};initial catalog={1};persist security info=True;user id={2};password={3};multipleactiveresultsets=True" />
9
	</connectionStrings>
10
	<userSettings>
11
		<ID2.Manager.Properties.Settings>
12
			<setting name="MarkusService" serializeAs="String"  xdt:Transform="Replace"  xdt:Locator="Match(name)">
13
				<value>http://12.127.163.230:9991/ImageCreateAPI</value>
14
			</setting>
15
		</ID2.Manager.Properties.Settings>
16
	</userSettings>
17
</configuration>
ID2.Manager/ID2.Manager.Compare/App.config
1
<?xml version="1.0" encoding="utf-8"?>
2
<configuration>
3
  <configSections>
4
    <sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
5
      <section name="ID2.Manager.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
6
    </sectionGroup>
7
    <sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
8
      <section name="ID2.Manager.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
9
    </sectionGroup>
10
  </configSections>
11
  <startup>
12
    <supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.8" />
13
  </startup>
14
  <connectionStrings>
15
    <add name="ID2Manager" providerName="System.Data.SqlClient" connectionString="data source=192.168.0.67;initial catalog=ID2Manager;persist security info=True;user id=sa;password=dof1073#;multipleactiveresultsets=True" />
16
    <add name="Markus" providerName="System.Data.SqlClient" connectionString="data source=192.168.0.67;initial catalog=Markus_SEC;persist security info=True;user id=doftech;password=dof1073#;multipleactiveresultsets=True" />
17
    <add name="ID2Project" providerName="System.Data.SqlClient" connectionString="data source={0};initial catalog={1};persist security info=True;user id={2};password={3};multipleactiveresultsets=True" />
18
  </connectionStrings>
19
  <appSettings>
20
    <!--add key="ID2" value="%USERNAME%\Digital PID\Project.db" /-->
21
    <add key="ID2SQLiteInfo" value="Digital PID\Project.db" />
22
    <add key="ID2SQLite" value="Data Source={0};Version=3;" />
23
    <add key="ClientSettingsProvider.ServiceUri" value="" />
24
  </appSettings>
25
  <userSettings>
26
    <ID2.Manager.Properties.Settings>
27
      <setting name="GemBoxLicense" serializeAs="String">
28
        <value>SN-2021May25-IPYYaC5T2J/LIzFImndeajkkMS/Fn1fLWGfjRRxTNu/uan2hm9KrTK/v9hdsQfLCOuUeMZXrEHCPsmS7Pnp4YGIGsOw==A</value>
29
      </setting>
30
      <setting name="UserInfo" serializeAs="String">
31
        <value />
32
      </setting>
33
      <setting name="ID2SQLiteInfo" serializeAs="String">
34
        <value />
35
      </setting>
36
      <setting name="MarkusService" serializeAs="String">
37
        <value>http://192.168.0.147:9991/Markusapi/MarkusImageCreateAPI</value>
38
      </setting>
39
    </ID2.Manager.Properties.Settings>
40
  </userSettings>
41
  <applicationSettings>
42
    <ID2.Manager.Properties.Settings>
43
      <setting name="ID2Port" serializeAs="String">
44
        <value>2549</value>
45
      </setting>
46
    </ID2.Manager.Properties.Settings>
47
  </applicationSettings>
48
  <system.web>
49
    <membership defaultProvider="ClientAuthenticationMembershipProvider">
50
      <providers>
51
        <add name="ClientAuthenticationMembershipProvider" type="System.Web.ClientServices.Providers.ClientFormsAuthenticationMembershipProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" />
52
      </providers>
53
    </membership>
54
    <roleManager defaultProvider="ClientRoleProvider" enabled="true">
55
      <providers>
56
        <add name="ClientRoleProvider" type="System.Web.ClientServices.Providers.ClientRoleProvider, System.Web.Extensions, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" serviceUri="" cacheTimeout="86400" />
57
      </providers>
58
    </roleManager>
59
  </system.web>
60
</configuration>
ID2.Manager/ID2.Manager.Compare/Classes/BaseWorker.cs
1
using System;
2
using System.Collections.Generic;
3
using System.Linq;
4
using System.Text;
5
using System.Threading.Tasks;
6

  
7
using System.ComponentModel;
8

  
9
using Telerik.WinControls.UI;
10

  
11
namespace ID2.Manager.Classes
12
{
13
    public class BaseWorker
14
    {
15
        protected System.Windows.Forms.Control _parent = null;
16
        private BackgroundWorker worker = new BackgroundWorker() { WorkerReportsProgress = true, WorkerSupportsCancellation = true };
17
        private RadWaitingBar waiting = null;
18

  
19
        public BaseWorker(System.Windows.Forms.Control control = null)
20
        {
21
            this._parent = control;
22
        }
23

  
24
        public virtual void StartWork()
25
        {
26
            if (_parent != null)
27
            {
28
                _parent.Invoke(new Action(() =>
29
                {
30
                    waiting = new RadWaitingBar()
31
                    {
32
                        Size = new System.Drawing.Size(200, 200),
33
                        WaitingStyle = Telerik.WinControls.Enumerations.WaitingBarStyles.DotsSpinner,
34
                        BackColor = System.Drawing.Color.Transparent,
35
                        Parent = _parent
36
                    };
37
                    waiting.Location = new System.Drawing.Point(
38
                        _parent.Location.X + (_parent.Width - waiting.Width) / 2,
39
                        _parent.Location.Y + (_parent.Height - waiting.Height) / 2);
40
                    _parent.Controls.Add(waiting);
41
                }));
42
            }
43

  
44
            worker.DoWork += Worker_DoWork;
45
            worker.ProgressChanged += Worker_ProgressChanged;
46
            worker.RunWorkerCompleted += Worker_RunWorkerCompleted;
47
            if (!worker.IsBusy)
48
            {
49
                if (this.waiting != null) this.waiting.StartWaiting();
50
                worker.RunWorkerAsync();
51
            }
52
        }
53

  
54
        public virtual void CancelWork()
55
        {
56
            this.worker.CancelAsync();
57
        }
58

  
59
        private void Worker_ProgressChanged(object sender, ProgressChangedEventArgs e)
60
        {
61
            this.UpdateProgress(e.ProgressPercentage);
62
        }
63

  
64
        private void Worker_RunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e)
65
        {
66
            if (this.waiting != null)
67
            {
68
                try
69
                {
70
                    this.waiting.StopWaiting();
71
                    if (this._parent != null)
72
                    {
73
                        this._parent.Invoke(new Action(() => this._parent.Controls.Remove(this.waiting)));
74

  
75
                    }
76
                    this.waiting.Dispose();
77
                }
78
                catch (Exception ex)
79
                {
80
                    Console.WriteLine(ex.Message);
81
                }
82
            }
83
            this.WorkCompleted(e);
84
        }
85

  
86
        private void Worker_DoWork(object sender, DoWorkEventArgs e)
87
        {
88
            this.DoWork(sender as BackgroundWorker, e);
89
        }
90

  
91
        protected virtual void DoWork(System.ComponentModel.BackgroundWorker worker, DoWorkEventArgs args) { throw new NotImplementedException(); }
92
        protected virtual void UpdateProgress(int precent) { }
93
        protected virtual void WorkCompleted(RunWorkerCompletedEventArgs args) { }
94
    }
95
}
ID2.Manager/ID2.Manager.Compare/Classes/ID2Helper.cs
1
using Newtonsoft.Json;
2
using System;
3
using System.Collections.Generic;
4
using System.Diagnostics;
5
using System.Linq;
6
using System.Net.Sockets;
7
using System.Reflection;
8
using System.Runtime.InteropServices;
9
using System.Text;
10
using System.Threading.Tasks;
11

  
12
namespace ID2.Manager.Classes
13
{
14
    public static class ID2Helper
15
    {
16
        [DllImport("kernel32")]
17
        private static extern long WritePrivateProfileString(string section, string key, string val, string filePath);
18
        [DllImport("kernel32")]
19
        private static extern int GetPrivateProfileString(string section, string key, string def, StringBuilder retVal, int size, string filePath);
20
        [DllImport("kernel32.dll")]
21
        private static extern int GetPrivateProfileSection(string lpAppName, byte[] lpszReturnBuffer, int nSize, string lpFileName);
22

  
23
        /// <summary>
24
        /// 주어진 DrawingName의 도면을 ID2에서 엽니다.
25
        /// </summary>
26
        /// <param name="DrawingName"></param>
27
        /// <param name="uids"></param>
28
        public static void OpenPID(string DrawingName, string uids, int port)
29
        {
30
            using (TcpClient tcpClient = new TcpClient())
31
            {
32
                try
33
                {
34
                    tcpClient.SendTimeout = 500;
35
                    tcpClient.Connect("localhost", port);
36

  
37
                    var _params = new Dictionary<string, string>()
38
                    {
39
                        { "request", "open drawing" },
40
                        { "drawing", DrawingName },
41
                        { "oid", uids }
42
                    };
43
                    string json = JsonConvert.SerializeObject(_params, Formatting.Indented);
44

  
45
                    byte[] message = Encoding.UTF8.GetBytes(json);
46

  
47
                    using (NetworkStream networkStream = tcpClient.GetStream())
48
                    {
49
                        networkStream.Write(message, 0, message.Length);
50

  
51
                        byte[] outbuf = new byte[1024];
52
                        int nbytes = networkStream.Read(outbuf, 0, outbuf.Length);
53
                        string output = Encoding.UTF8.GetString(outbuf, 4, nbytes - 5);
54
                        var result = JsonConvert.DeserializeObject<Dictionary<string, string>>(output);
55
                    }
56
                }
57
                catch (Exception ex)
58
                {
59
                    throw ex;
60
                }
61
            }
62
        }
63

  
64
        /// <summary>
65
        /// Write Data to the INI File
66
        /// </summary>
67
        /// <PARAM name="Section"></PARAM>
68
        /// Section name
69
        /// <PARAM name="Key"></PARAM>
70
        /// Key Name
71
        /// <PARAM name="Value"></PARAM>
72
        /// Value Name
73
        public static void IniWriteValue(string sPath, string Section, string Key, string Value)
74
        {
75
            WritePrivateProfileString(Section, Key, Value, sPath);
76
        }
77

  
78
        /// <summary>
79
        /// Read Data Value From the Ini File
80
        /// </summary>
81
        /// <PARAM name="Section"></PARAM>
82
        /// <PARAM name="Key"></PARAM>
83
        /// <PARAM name="Path"></PARAM>
84
        /// <returns></returns>
85
        public static string IniReadValue(string sPath, string Section, string Key)
86
        {
87
            StringBuilder temp = new StringBuilder(255);
88
            int i = GetPrivateProfileString(Section, Key, string.Empty, temp, 255, sPath);
89
            return temp.ToString();
90
        }
91
    }
92
}
ID2.Manager/ID2.Manager.Compare/Classes/LinqExtension.cs
1
using System;
2
using System.Collections.Generic;
3
using System.Linq;
4
using System.Text;
5
using System.Threading.Tasks;
6

  
7
namespace ID2.Manager.Classes
8
{
9
    public static class LinqExtension
10
    {
11
        public static void ForAll<T>(this IEnumerable<T> collection, Action<T> action)
12
        {
13
            foreach (var item in collection)
14
            {
15
                action(item);
16
            }
17
        }
18
        public static void ParallelForAll<T>(this IEnumerable<T> collection, Action<T> action)
19
        {
20
            Parallel.ForEach(collection, item => action(item));
21
        }
22

  
23
        public static T Find<T>(this IEnumerable<T> collection, Predicate<T> selector)
24
        {
25
            foreach (var item in collection)
26
            {
27
                var value = selector(item);
28

  
29
                if (value)
30
                    return item;
31
            }
32

  
33
            return default(T);
34
        }
35

  
36
        static public bool ContainsAll<T>(this IEnumerable<T> owner, IEnumerable<T> contain)
37
        {
38
            foreach (var item in owner)
39
            {
40
                if (!contain.Contains(item))
41
                {
42
                    return false;
43
                }
44
            }
45

  
46
            return true;
47
        }
48
    }
49
}
ID2.Manager/ID2.Manager.Compare/Controls/DetailGridViewTemplate.cs
1
using System;
2
using System.Collections.Generic;
3
using System.Linq;
4
using System.Text;
5
using System.Threading.Tasks;
6
using Telerik.WinControls.UI;
7

  
8
namespace ID2.Manager.Controls
9
{
10
    public class DetailGridViewTemplate : GridViewTemplate
11
    {
12
        public DetailGridViewTemplate()
13
        {
14
            this.AllowAddNewRow = false;
15
            this.AllowEditRow = false;
16
            this.ShowColumnHeaders = false;
17
        }
18
    }
19
}
ID2.Manager/ID2.Manager.Compare/Controls/PDFViewer.Designer.cs
1

2
namespace ID2.Manager.Controls
3
{
4
    partial class PDFViewer
5
    {
6
        /// <summary> 
7
        /// 필수 디자이너 변수입니다.
8
        /// </summary>
9
        private System.ComponentModel.IContainer components = null;
10

  
11
        /// <summary> 
12
        /// 사용 중인 모든 리소스를 정리합니다.
13
        /// </summary>
14
        /// <param name="disposing">관리되는 리소스를 삭제해야 하면 true이고, 그렇지 않으면 false입니다.</param>
15
        protected override void Dispose(bool disposing)
16
        {
17
            if (disposing && (components != null))
18
            {
19
                components.Dispose();
20
            }
21
            base.Dispose(disposing);
22
        }
23

  
24
        #region 구성 요소 디자이너에서 생성한 코드
25

  
26
        /// <summary> 
27
        /// 디자이너 지원에 필요한 메서드입니다. 
28
        /// 이 메서드의 내용을 코드 편집기로 수정하지 마세요.
29
        /// </summary>
30
        private void InitializeComponent()
31
        {
32
            this.components = new System.ComponentModel.Container();
33
            devDept.Eyeshot.CancelToolBarButton cancelToolBarButton1 = new devDept.Eyeshot.CancelToolBarButton("Cancel", devDept.Eyeshot.ToolBarButton.styleType.ToggleButton, true, true);
34
            devDept.Eyeshot.ProgressBar progressBar1 = new devDept.Eyeshot.ProgressBar(devDept.Eyeshot.ProgressBar.styleType.Circular, 0, "Idle", System.Drawing.Color.Black, System.Drawing.Color.Transparent, System.Drawing.Color.Green, 1D, true, cancelToolBarButton1, false, 0.1D, 0.333D, true);
35
            devDept.Graphics.BackgroundSettings backgroundSettings1 = new devDept.Graphics.BackgroundSettings(devDept.Graphics.backgroundStyleType.Solid, System.Drawing.Color.DeepSkyBlue, System.Drawing.Color.DodgerBlue, System.Drawing.Color.Black, 0.75D, null, devDept.Graphics.colorThemeType.Auto, 0.33D);
36
            devDept.Eyeshot.Camera camera1 = new devDept.Eyeshot.Camera(new devDept.Geometry.Point3D(-4.5374030325107811E-16D, 2.0434646606445308D, 47.596564948558793D), 97.257904648780823D, new devDept.Geometry.Quaternion(0.49999999999999989D, 0.5D, 0.5D, 0.50000000000000011D), devDept.Graphics.projectionType.Orthographic, 40D, 1.497090233266769D, false, 0.001D);
37
            devDept.Eyeshot.MagnifyingGlassToolBarButton magnifyingGlassToolBarButton1 = new devDept.Eyeshot.MagnifyingGlassToolBarButton("Magnifying Glass", devDept.Eyeshot.ToolBarButton.styleType.ToggleButton, true, true);
38
            devDept.Eyeshot.ZoomWindowToolBarButton zoomWindowToolBarButton1 = new devDept.Eyeshot.ZoomWindowToolBarButton("Zoom Window", devDept.Eyeshot.ToolBarButton.styleType.ToggleButton, true, true);
39
            devDept.Eyeshot.ZoomToolBarButton zoomToolBarButton1 = new devDept.Eyeshot.ZoomToolBarButton("Zoom", devDept.Eyeshot.ToolBarButton.styleType.ToggleButton, true, true);
40
            devDept.Eyeshot.PanToolBarButton panToolBarButton1 = new devDept.Eyeshot.PanToolBarButton("Pan", devDept.Eyeshot.ToolBarButton.styleType.ToggleButton, true, true);
41
            devDept.Eyeshot.ZoomFitToolBarButton zoomFitToolBarButton1 = new devDept.Eyeshot.ZoomFitToolBarButton("Zoom Fit", devDept.Eyeshot.ToolBarButton.styleType.PushButton, true, true);
42
            devDept.Eyeshot.ToolBar toolBar1 = new devDept.Eyeshot.ToolBar(devDept.Eyeshot.ToolBar.positionType.HorizontalTopCenter, true, new devDept.Eyeshot.ToolBarButton[] {
43
            ((devDept.Eyeshot.ToolBarButton)(magnifyingGlassToolBarButton1)),
44
            ((devDept.Eyeshot.ToolBarButton)(zoomWindowToolBarButton1)),
45
            ((devDept.Eyeshot.ToolBarButton)(zoomToolBarButton1)),
46
            ((devDept.Eyeshot.ToolBarButton)(panToolBarButton1)),
47
            ((devDept.Eyeshot.ToolBarButton)(zoomFitToolBarButton1))});
48
            devDept.Eyeshot.Histogram histogram1 = new devDept.Eyeshot.Histogram(30, 80, "Title", System.Drawing.Color.Blue, System.Drawing.Color.Gray, System.Drawing.Color.Black, System.Drawing.Color.Red, System.Drawing.Color.LightYellow, false, true, false, "{0:+0.###;-0.###;0}");
49
            devDept.Eyeshot.Grid grid1 = new devDept.Eyeshot.Grid(new devDept.Geometry.Point2D(-100D, -100D), new devDept.Geometry.Point2D(100D, 100D), 10D, new devDept.Geometry.Plane(new devDept.Geometry.Point3D(0D, 0D, 0D), new devDept.Geometry.Vector3D(0D, 0D, 1D)), System.Drawing.Color.FromArgb(((int)(((byte)(63)))), ((int)(((byte)(128)))), ((int)(((byte)(128)))), ((int)(((byte)(128))))), System.Drawing.Color.FromArgb(((int)(((byte)(127)))), ((int)(((byte)(255)))), ((int)(((byte)(0)))), ((int)(((byte)(0))))), System.Drawing.Color.FromArgb(((int)(((byte)(127)))), ((int)(((byte)(0)))), ((int)(((byte)(128)))), ((int)(((byte)(0))))), false, false, false, false, 10, 100, 10, System.Drawing.Color.FromArgb(((int)(((byte)(127)))), ((int)(((byte)(90)))), ((int)(((byte)(90)))), ((int)(((byte)(90))))), System.Drawing.Color.Transparent, false, System.Drawing.Color.FromArgb(((int)(((byte)(12)))), ((int)(((byte)(0)))), ((int)(((byte)(0)))), ((int)(((byte)(255))))));
50
            devDept.Eyeshot.OriginSymbol originSymbol1 = new devDept.Eyeshot.OriginSymbol(10, devDept.Eyeshot.originSymbolStyleType.Ball, new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))), System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.Red, System.Drawing.Color.Green, System.Drawing.Color.Blue, "Origin", "X", "Y", "Z", true, null, false);
51
            devDept.Eyeshot.RotateSettings rotateSettings1 = new devDept.Eyeshot.RotateSettings(new devDept.Eyeshot.MouseButton(devDept.Eyeshot.mouseButtonsZPR.Middle, devDept.Eyeshot.modifierKeys.None), 10D, false, 1D, devDept.Eyeshot.rotationType.Trackball, devDept.Eyeshot.rotationCenterType.CursorLocation, new devDept.Geometry.Point3D(0D, 0D, 0D), false);
52
            devDept.Eyeshot.ZoomSettings zoomSettings1 = new devDept.Eyeshot.ZoomSettings(new devDept.Eyeshot.MouseButton(devDept.Eyeshot.mouseButtonsZPR.Middle, devDept.Eyeshot.modifierKeys.Shift), 25, true, devDept.Eyeshot.zoomStyleType.AtCursorLocation, false, 1D, System.Drawing.Color.Empty, devDept.Eyeshot.Camera.perspectiveFitType.Accurate, false, 10, true);
53
            devDept.Eyeshot.PanSettings panSettings1 = new devDept.Eyeshot.PanSettings(new devDept.Eyeshot.MouseButton(devDept.Eyeshot.mouseButtonsZPR.Middle, devDept.Eyeshot.modifierKeys.Ctrl), 25, true);
54
            devDept.Eyeshot.NavigationSettings navigationSettings1 = new devDept.Eyeshot.NavigationSettings(devDept.Eyeshot.Camera.navigationType.Examine, new devDept.Eyeshot.MouseButton(devDept.Eyeshot.mouseButtonsZPR.Left, devDept.Eyeshot.modifierKeys.None), new devDept.Geometry.Point3D(-1000D, -1000D, -1000D), new devDept.Geometry.Point3D(1000D, 1000D, 1000D), 8D, 50D, 50D);
55
            devDept.Eyeshot.CoordinateSystemIcon coordinateSystemIcon1 = new devDept.Eyeshot.CoordinateSystemIcon(new System.Drawing.Font("굴림", 9F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(129))), System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.Black, System.Drawing.Color.FromArgb(((int)(((byte)(80)))), ((int)(((byte)(80)))), ((int)(((byte)(80))))), System.Drawing.Color.FromArgb(((int)(((byte)(80)))), ((int)(((byte)(80)))), ((int)(((byte)(80))))), System.Drawing.Color.OrangeRed, "Origin", "X", "Y", "Z", true, devDept.Eyeshot.coordinateSystemPositionType.BottomLeft, 37, null, false);
56
            devDept.Eyeshot.ViewCubeIcon viewCubeIcon1 = new devDept.Eyeshot.ViewCubeIcon(devDept.Eyeshot.coordinateSystemPositionType.TopRight, false, System.Drawing.Color.FromArgb(((int)(((byte)(220)))), ((int)(((byte)(20)))), ((int)(((byte)(60))))), true, "FRONT", "BACK", "LEFT", "RIGHT", "TOP", "BOTTOM", System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), System.Drawing.Color.FromArgb(((int)(((byte)(240)))), ((int)(((byte)(77)))), ((int)(((byte)(77)))), ((int)(((byte)(77))))), 'S', 'N', 'W', 'E', true, null, System.Drawing.Color.White, System.Drawing.Color.Black, 120, true, true, null, null, null, null, null, null, false, new devDept.Geometry.Quaternion(0D, 0D, 0D, 1D), true);
57
            devDept.Eyeshot.Viewport.SavedViewsManager savedViewsManager1 = new devDept.Eyeshot.Viewport.SavedViewsManager(8);
58
            devDept.Eyeshot.Viewport viewport1 = new devDept.Eyeshot.Viewport(new System.Drawing.Point(0, 0), new System.Drawing.Size(487, 360), backgroundSettings1, camera1, new devDept.Eyeshot.ToolBar[] {
59
            toolBar1}, new devDept.Eyeshot.Legend[0], histogram1, devDept.Eyeshot.displayType.Wireframe, true, false, false, false, new devDept.Eyeshot.Grid[] {
60
            grid1}, new devDept.Eyeshot.OriginSymbol[] {
61
            originSymbol1}, false, rotateSettings1, zoomSettings1, panSettings1, navigationSettings1, coordinateSystemIcon1, viewCubeIcon1, savedViewsManager1, devDept.Eyeshot.viewType.Top);
62
            this.myModelDWG = new Xtractor.Viewer.MyModel(this.components);
63
            ((System.ComponentModel.ISupportInitialize)(this.myModelDWG)).BeginInit();
64
            this.SuspendLayout();
65
            // 
66
            // myModelDWG
67
            // 
68
            this.myModelDWG.Cursor = System.Windows.Forms.Cursors.Default;
69
            this.myModelDWG.Dock = System.Windows.Forms.DockStyle.Fill;
70
            this.myModelDWG.Location = new System.Drawing.Point(0, 0);
71
            this.myModelDWG.Name = "myModelDWG";
72
            this.myModelDWG.ProgressBar = progressBar1;
73
            this.myModelDWG.Size = new System.Drawing.Size(487, 360);
74
            this.myModelDWG.TabIndex = 1;
75
            this.myModelDWG.Viewports.Add(viewport1);
76
            // 
77
            // AutoCADViewer
78
            // 
79
            this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 12F);
80
            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
81
            this.Controls.Add(this.myModelDWG);
82
            this.Name = "AutoCADViewer";
83
            this.Size = new System.Drawing.Size(487, 360);
84
            ((System.ComponentModel.ISupportInitialize)(this.myModelDWG)).EndInit();
85
            this.ResumeLayout(false);
86

  
87
        }
88

  
89
        #endregion
90

  
91
        private Xtractor.Viewer.MyModel myModelDWG;
92
    }
93
}
ID2.Manager/ID2.Manager.Compare/Controls/PDFViewer.cs
1
using System;
2
using System.Collections.Generic;
3
using System.ComponentModel;
4
using System.Data;
5
using System.Drawing;
6
using System.Linq;
7
using System.Text;
8
using System.Threading.Tasks;
9
using System.Windows.Forms;
10

  
11
namespace ID2.Manager.Controls
12
{
13
    public partial class PDFViewer : UserControl
14
    {
15
        private Telerik.WinControls.UI.RadPdfViewer radPdfViewerDWG;
16

  
17
        public PDFViewer()
18
        {
19
            InitializeComponent();
20
        }
21

  
22
        private void InitializeComponent()
23
        {
24
            this.radPdfViewerDWG = new Telerik.WinControls.UI.RadPdfViewer();
25
            ((System.ComponentModel.ISupportInitialize)(this.radPdfViewerDWG)).BeginInit();
26
            this.SuspendLayout();
27
            // 
28
            // radPdfViewerDWG
29
            // 
30
            this.radPdfViewerDWG.AutoScroll = true;
31
            this.radPdfViewerDWG.Dock = System.Windows.Forms.DockStyle.Fill;
32
            this.radPdfViewerDWG.EnableThumbnails = false;
33
            this.radPdfViewerDWG.FitToWidth = true;
34
            this.radPdfViewerDWG.Location = new System.Drawing.Point(0, 0);
35
            this.radPdfViewerDWG.Name = "radPdfViewerDWG";
36
            this.radPdfViewerDWG.Size = new System.Drawing.Size(315, 290);
37
            this.radPdfViewerDWG.TabIndex = 0;
38
            this.radPdfViewerDWG.ThumbnailsScaleFactor = 0.15F;
39
            // 
40
            // PDFViewer
41
            // 
42
            this.Controls.Add(this.radPdfViewerDWG);
43
            this.Name = "PDFViewer";
44
            this.Size = new System.Drawing.Size(315, 290);
45
            ((System.ComponentModel.ISupportInitialize)(this.radPdfViewerDWG)).EndInit();
46
            this.ResumeLayout(false);
47

  
48
        }
49

  
50
        /// <summary>
51
        /// pdf 파일을 읽어 화면에 표시합니다.
52
        /// </summary>
53
        /// <param name="PDFFilePath"></param>
54
        public void ReadPDF(string PDFFilePath)
55
        {
56
            if (System.IO.File.Exists(PDFFilePath))
57
            {
58
                this.radPdfViewerDWG.LoadDocument(PDFFilePath);
59
            }
60
        }
61
    }
62
}
ID2.Manager/ID2.Manager.Compare/Controls/PDFViewer.cs.bak
1
using System;
2
using System.Collections.Generic;
3
using System.ComponentModel;
4
using System.Data;
5
using System.Drawing;
6
using System.Linq;
7
using System.Text;
8
using System.Threading.Tasks;
9
using System.Windows.Forms;
10

  
11
namespace ID2.Manager.Controls
12
{
13
    public partial class PDFViewer : UserControl
14
    {
15
        private Telerik.WinControls.UI.RadPdfViewer radPdfViewerDWG;
16

  
17
        public PDFViewer()
18
        {
19
            InitializeComponent();
20
        }
21

  
22
        private void InitializeComponent()
23
        {
24
            this.radPdfViewerDWG = new Telerik.WinControls.UI.RadPdfViewer();
25
            ((System.ComponentModel.ISupportInitialize)(this.radPdfViewerDWG)).BeginInit();
26
            this.SuspendLayout();
27
            // 
28
            // radPdfViewerDWG
29
            // 
30
            this.radPdfViewerDWG.AutoScroll = true;
31
            this.radPdfViewerDWG.Dock = System.Windows.Forms.DockStyle.Fill;
32
            this.radPdfViewerDWG.EnableThumbnails = false;
33
            this.radPdfViewerDWG.FitToWidth = true;
34
            this.radPdfViewerDWG.Location = new System.Drawing.Point(0, 0);
35
            this.radPdfViewerDWG.Name = "radPdfViewerDWG";
36
            this.radPdfViewerDWG.Size = new System.Drawing.Size(315, 290);
37
            this.radPdfViewerDWG.TabIndex = 0;
38
            this.radPdfViewerDWG.ThumbnailsScaleFactor = 0.15F;
39
            // 
40
            // PDFViewer
41
            // 
42
            this.Controls.Add(this.radPdfViewerDWG);
43
            this.Name = "PDFViewer";
44
            this.Size = new System.Drawing.Size(315, 290);
45
            ((System.ComponentModel.ISupportInitialize)(this.radPdfViewerDWG)).EndInit();
46
            this.ResumeLayout(false);
47

  
48
        }
49

  
50
        /// <summary>
51
        /// pdf 파일을 읽어 화면에 표시합니다.
52
        /// </summary>
53
        /// <param name="PDFFilePath"></param>
54
        public void ReadPDF(string PDFFilePath)
55
        {
56
            if (System.IO.File.Exists(PDFFilePath))
57
            {
58
                this.radPdfViewerDWG.LoadDocument(PDFFilePath);
59
                this.radPdfViewerDWG.Visible = true;
60
            }
61
        }
62
    }
63
}
ID2.Manager/ID2.Manager.Compare/Controls/PDFViewer.resx
1
<?xml version="1.0" encoding="utf-8"?>
2
<root>
3
  <!-- 
4
    Microsoft ResX Schema 
5
    
6
    Version 2.0
7
    
8
    The primary goals of this format is to allow a simple XML format 
9
    that is mostly human readable. The generation and parsing of the 
10
    various data types are done through the TypeConverter classes 
11
    associated with the data types.
12
    
13
    Example:
14
    
15
    ... ado.net/XML headers & schema ...
16
    <resheader name="resmimetype">text/microsoft-resx</resheader>
17
    <resheader name="version">2.0</resheader>
18
    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
19
    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
20
    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
21
    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
22
    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
23
        <value>[base64 mime encoded serialized .NET Framework object]</value>
24
    </data>
25
    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
26
        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
27
        <comment>This is a comment</comment>
28
    </data>
29
                
30
    There are any number of "resheader" rows that contain simple 
31
    name/value pairs.
32
    
33
    Each data row contains a name, and value. The row also contains a 
34
    type or mimetype. Type corresponds to a .NET class that support 
35
    text/value conversion through the TypeConverter architecture. 
36
    Classes that don't support this are serialized and stored with the 
37
    mimetype set.
38
    
39
    The mimetype is used for serialized objects, and tells the 
40
    ResXResourceReader how to depersist the object. This is currently not 
41
    extensible. For a given mimetype the value must be set accordingly:
42
    
43
    Note - application/x-microsoft.net.object.binary.base64 is the format 
44
    that the ResXResourceWriter will generate, however the reader can 
45
    read any of the formats listed below.
46
    
47
    mimetype: application/x-microsoft.net.object.binary.base64
48
    value   : The object must be serialized with 
49
            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
50
            : and then encoded with base64 encoding.
51
    
52
    mimetype: application/x-microsoft.net.object.soap.base64
53
    value   : The object must be serialized with 
54
            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
55
            : and then encoded with base64 encoding.
56

  
57
    mimetype: application/x-microsoft.net.object.bytearray.base64
58
    value   : The object must be serialized into a byte array 
59
            : using a System.ComponentModel.TypeConverter
60
            : and then encoded with base64 encoding.
61
    -->
62
  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
63
    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
64
    <xsd:element name="root" msdata:IsDataSet="true">
65
      <xsd:complexType>
66
        <xsd:choice maxOccurs="unbounded">
67
          <xsd:element name="metadata">
68
            <xsd:complexType>
69
              <xsd:sequence>
70
                <xsd:element name="value" type="xsd:string" minOccurs="0" />
71
              </xsd:sequence>
72
              <xsd:attribute name="name" use="required" type="xsd:string" />
73
              <xsd:attribute name="type" type="xsd:string" />
74
              <xsd:attribute name="mimetype" type="xsd:string" />
75
              <xsd:attribute ref="xml:space" />
76
            </xsd:complexType>
77
          </xsd:element>
78
          <xsd:element name="assembly">
79
            <xsd:complexType>
80
              <xsd:attribute name="alias" type="xsd:string" />
81
              <xsd:attribute name="name" type="xsd:string" />
82
            </xsd:complexType>
83
          </xsd:element>
84
          <xsd:element name="data">
85
            <xsd:complexType>
86
              <xsd:sequence>
87
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
88
                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
89
              </xsd:sequence>
90
              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
91
              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
92
              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
93
              <xsd:attribute ref="xml:space" />
94
            </xsd:complexType>
95
          </xsd:element>
96
          <xsd:element name="resheader">
97
            <xsd:complexType>
98
              <xsd:sequence>
99
                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
100
              </xsd:sequence>
101
              <xsd:attribute name="name" type="xsd:string" use="required" />
102
            </xsd:complexType>
103
          </xsd:element>
104
        </xsd:choice>
105
      </xsd:complexType>
106
    </xsd:element>
107
  </xsd:schema>
108
  <resheader name="resmimetype">
109
    <value>text/microsoft-resx</value>
110
  </resheader>
111
  <resheader name="version">
112
    <value>2.0</value>
113
  </resheader>
114
  <resheader name="reader">
115
    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
116
  </resheader>
117
  <resheader name="writer">
118
    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
119
  </resheader>
120
</root>
ID2.Manager/ID2.Manager.Compare/Controls/SearchRow.cs
1
using System;
2
using System.Collections.Generic;
3
using System.Linq;
4
using System.Text;
5
using System.Threading.Tasks;
6
using Telerik.WinControls.UI;
7

  
8
namespace ID2.Manager.Controls
9
{
10
    public class SearchRow : GridViewSearchRowInfo
11
    {
12
        public SearchRow(GridViewInfo viewInfo) : base(viewInfo)
13
        {
14
           
15
        }
16

  
17
        protected override bool MatchesSearchCriteria(string searchCriteria, GridViewRowInfo row, GridViewColumn col)
18
        {
19
            if (row is GridViewSummaryRowInfo)
20
            {
21
                return false;
22
            }
23
            return base.MatchesSearchCriteria(searchCriteria, row, col);
24
        }
25

  
26
        protected override void ReportSearchProgress(int percent, GridSearchResultCellInfo resultCell, GridSearchResultCellCollection resultCells)
27
        {
28
            base.ReportSearchProgress(percent, resultCell, resultCells);
29
        }
30
    }
31
}
ID2.Manager/ID2.Manager.Compare/Controls/Verification-.cs
1
using devDept.Eyeshot;
2
using devDept.Eyeshot.Entities;
3
using devDept.Geometry.Entities;
4
using ID2.Manager.Common;
5
using ID2.Manager.Data.Models;
6
using System;
7
using System.Collections.Generic;
8
using System.ComponentModel;
9
using System.Data;
10
using System.Drawing;
11
using System.Linq;
12
using System.Runtime.InteropServices;
13
using System.Text;
14
using System.Threading.Tasks;
15
using System.Windows.Forms;
16
using Telerik.WinControls;
17

  
18
namespace ID2.Manager.Controls
19
{
20
    public partial class Verification : UserControl
21
    {
22
        public delegate void DocumentSelected(Documents doc);
23
        public event DocumentSelected OnDocumentSelected;
24

  
25
        readonly Informations informations = Informations.Instance;
26
        readonly string IniFilePath = System.IO.Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), 
27
            Application.ProductName, $"{Application.ProductName}.ini");
28

  
29
        private static Color EqualColor = Color.FromArgb(44, 44, 44);
30
        private static Color DiffColor = Color.Yellow;
31
        private static double Tolerance = 0;
32

  
33
        public Verification()
34
        {
35
            InitializeComponent();
36
            this.radGridViewDocument.AutoSizeColumnsMode = Telerik.WinControls.UI.GridViewAutoSizeColumnsMode.Fill;
37

  
38
            this.Load += Verification_Load;
39
            this.radGridViewDocument.SelectionChanged += RadGridViewDocument_SelectionChanged;
40
            this.radBrowseEditorAVEVAPIDFolder.ValueChanged += RadBrowseEditorAVEVAPIDFolder_ValueChanged;
41
            this.radSpinEditorTolerance.ValueChanged += RadSpinEditorTolerance_ValueChanged;
42
            this.radColorBoxEqualColor.ValueChanged += RadColorBoxEqualColor_ValueChanged;
43
            this.radColorBoxDiffColor.ValueChanged += RadColorBoxDiffColor_ValueChanged;
44

  
45
            this.designAutoCAD.ActionMode = actionType.SelectVisibleByPickDynamic;
46
            this.designAutoCAD.Selection.ColorDynamic = Color.FromArgb(80, Color.OrangeRed);
47
            this.designAutoCAD.Selection.HaloInnerColor = Color.FromArgb(255, Color.OrangeRed);
48
            this.designAutoCAD.Selection.HaloOuterColor = Color.FromArgb(64, Color.OrangeRed);
49
            this.designAutoCAD.Selection.HaloWidthPolygons = 4;
50
            this.designAutoCAD.Selection.HaloWidthWires = 2;
51

  
52
            this.designAVEVA.ActionMode = actionType.SelectVisibleByPickDynamic;
53

  
54
            #region Camera Sync
55
            this.designAutoCAD.ActiveViewport.Rotate.Enabled = false;
56
            this.designAVEVA.ActiveViewport.Rotate.Enabled = false;
57

  
58
            this.designAutoCAD.ActiveViewport.ViewCubeIcon.Visible = false;
59
            this.designAVEVA.ActiveViewport.ViewCubeIcon.Visible = false;
60

  
61
            this.designAutoCAD.AnimateCamera = false;
62
            this.designAVEVA.AnimateCamera = false;
63

  
64
            this.designAutoCAD.CameraChangedFrequency = 200;
65
            this.designAVEVA.CameraChangedFrequency = 200;
66

  
67
            this.designAutoCAD.CameraChanged += CameraChanged;
68
            this.designAVEVA.CameraChanged += CameraChanged;
69
            #endregion
70
        }
71

  
72

  
73

  
74
        /// <summary>
75
        /// 서로 다른 엔터티의 색상을 설정한다.
76
        /// </summary>
77
        /// <param name="sender"></param>
78
        /// <param name="e"></param>
79
        private void RadColorBoxDiffColor_ValueChanged(object sender, EventArgs e)
80
        {
81
            Verification.DiffColor = this.radColorBoxDiffColor.Value;
82
            string color = $"{Verification.DiffColor.R},{Verification.DiffColor.G},{Verification.DiffColor.B}";
83
            Classes.ID2Helper.IniWriteValue(IniFilePath, "Verification", "DiffColor", color);
84
        }
85

  
86
        /// <summary>
87
        /// 동일한 엔터티의 색상을 설정한다.
88
        /// </summary>
89
        /// <param name="sender"></param>
90
        /// <param name="e"></param>
91
        private void RadColorBoxEqualColor_ValueChanged(object sender, EventArgs e)
92
        {
93
            Verification.EqualColor = this.radColorBoxEqualColor.Value;
94
            string color = $"{Verification.EqualColor.R},{Verification.EqualColor.G},{Verification.EqualColor.B}";
95
            Classes.ID2Helper.IniWriteValue(IniFilePath, "Verification", "EqualColor", color);
96
        }
97

  
98
        /// <summary>
99
        /// 수정한 Tolerance를 시스템에 반영한다.
100
        /// </summary>
101
        /// <param name="sender"></param>
102
        /// <param name="e"></param>
103
        private void RadSpinEditorTolerance_ValueChanged(object sender, EventArgs e)
104
        {
105
            string AVEVAPIDFolder = this.radBrowseEditorAVEVAPIDFolder.Value;
106
            if (System.IO.Directory.Exists(AVEVAPIDFolder))
107
            {
108
                double toler = Convert.ToDouble(this.radSpinEditorTolerance.Value);
109
                Classes.ID2Helper.IniWriteValue(IniFilePath, "Verification", "Tolerance", toler.ToString());
110
                Verification.Tolerance = toler;
111
            }
112
        }
113

  
114
        private void RadBrowseEditorAVEVAPIDFolder_ValueChanged(object sender, EventArgs e)
115
        {
116
            string AVEVAPIDFolder = this.radBrowseEditorAVEVAPIDFolder.Value;
117
            if (System.IO.Directory.Exists(AVEVAPIDFolder))
118
            {
119
                Classes.ID2Helper.IniWriteValue(IniFilePath, "Path", "AVEVA P&ID Folder", AVEVAPIDFolder);
120
            }
121
        }
122

  
123
        private void Verification_Load(object sender, EventArgs e)
124
        {
125
            string AVEVAPIDFolder = Classes.ID2Helper.IniReadValue(IniFilePath, "Path", "AVEVA P&ID Folder");
126
            if (!string.IsNullOrEmpty(AVEVAPIDFolder)) this.radBrowseEditorAVEVAPIDFolder.Value = AVEVAPIDFolder;
127

  
128
            string Toler = Classes.ID2Helper.IniReadValue(IniFilePath, "Verification", "Tolerance");
129
            if (!string.IsNullOrEmpty(Toler))
130
            {
131
                this.radSpinEditorTolerance.Value = Convert.ToDecimal(Toler);
132
                Verification.Tolerance = Convert.ToDouble(this.radSpinEditorTolerance.Value);
133
            }
134

  
135
            string _EqualColor = Classes.ID2Helper.IniReadValue(IniFilePath, "Verification", "EqualColor");
136
            if (!string.IsNullOrEmpty(_EqualColor))
137
            {
138
                var tokens = _EqualColor.Split(',');
139
                if (tokens.Length == 3)
140
                {
141
                    this.radColorBoxEqualColor.Value =
142
                         Color.FromArgb(Convert.ToInt32(tokens[0]), Convert.ToInt32(tokens[1]), Convert.ToInt32(tokens[2]));
143
                }
144
            }
145

  
146
            string _DiffColor = Classes.ID2Helper.IniReadValue(IniFilePath, "Verification", "DiffColor");
147
            if (!string.IsNullOrEmpty(_DiffColor))
148
            {
149
                var tokens = _DiffColor.Split(',');
150
                if (tokens.Length == 3)
151
                {
152
                    this.radColorBoxDiffColor.Value =
153
                        Color.FromArgb(Convert.ToInt32(tokens[0]), Convert.ToInt32(tokens[1]), Convert.ToInt32(tokens[2]));
154
                }
155
            }
156
            string Layers = Classes.ID2Helper.IniReadValue(IniFilePath, "Verification", "Except Layers");
157
            if(!string.IsNullOrEmpty(Layers))
158
            {
159
                var InfoColl = Layers.Split(',').ToList().ConvertAll(x => new Forms.ExceptLayer.LayerInfo(x));
160
                InfoColl.ForEach(x => Forms.ExceptLayer.ExceptLayerInfoColl.Add(x));
161
            }
162

  
163
            this.radButtonExceptLayer.Click += RadButtonExceptLayer_Click;
164
        }
165
        /// <summary>
166
        /// Except Layer 폼을 띄운다.
167
        /// </summary>
168
        /// <param name="sender"></param>
169
        /// <param name="e"></param>
170
        private void RadButtonExceptLayer_Click(object sender, EventArgs e)
171
        {
172
            using (var frm = new Forms.ExceptLayer())
173

  
174
            {
175
                if(DialogResult.OK == frm.ShowDialog(this))
176
                {
177
                    string value = string.Join(",", Forms.ExceptLayer.ExceptLayerInfoColl.Select(x => x.Name));
178
                    Classes.ID2Helper.IniWriteValue(IniFilePath, "Verification", "Except Layers", value);
179
                }
180
            }
181
        }
182

  
183
        /// <summary>
184
        /// 엔터티들의 색상을 바꾼다.
185
        /// </summary>
186
        /// <param name="design"></param>
187
        /// <param name="list"></param>
188
        public void ColorEntities(Design design, EntityList list, Color color, colorMethodType colorMethod=colorMethodType.byEntity, bool ChangeBlkColor=true)
189
        {
190
            foreach (Entity ent in list)
191
            {
192
                ColorEntity(design, ent, color, colorMethod, ChangeBlkColor);
193
            }
194
        }
195

  
196
        /// <summary>
197
        /// 엔터티의 색상을 변경한다.
198
        /// </summary>
199
        /// <param name="design"></param>
200
        /// <param name="entity"></param>
201
        /// <param name="color"></param>
202
        private void ColorEntity(Design design, Entity entity, Color color, colorMethodType colorMethod = colorMethodType.byEntity, 
203
            bool ChangeBlkColor = true)
204
        {
205
            if (entity is BlockReference blkref)
206
            {
207
                blkref.Color = color;
208
                blkref.ColorMethod = colorMethod;
209

  
210
                if (ChangeBlkColor)
211
                {
212
                    var blk = design.Blocks.FirstOrDefault(x => x.Name == blkref.BlockName);
213
                    if (blk != null)
214
                    {
215
                        ColorEntities(design, blk.Entities, color, colorMethodType.byParent);
216
                        foreach (var attr in blkref.Attributes.Values)
217
                        {
218
                            attr.Color = color;
219
                            attr.ColorMethod = colorMethodType.byParent;
220
                        }
221
                    }
222
                }
223
            }
224
            else
225
            {
226
                entity.Color = color;
227
                entity.ColorMethod = colorMethod;
228
            }
229
        }
230

  
231
        /// <summary>
232
        /// 도면을 선택했을때 두 도면을 비교한다.
233
        /// </summary>
234
        /// <param name="sender"></param>
235
        /// <param name="e"></param>
236
        private void RadGridViewDocument_SelectionChanged(object sender, EventArgs e)
237
        {
238
            /// AutoCAD P&ID 파일을 화면에 표시한다.
239
            void ShowAutoCADFile(string FilePath)
240
            {
241
                this.designAutoCAD.Clear();
242
                if (System.IO.File.Exists(FilePath))
243
                {
244
                    try
245
                    {
246
                        devDept.Eyeshot.Translators.ReadAutodesk ra = new devDept.Eyeshot.Translators.ReadAutodesk(FilePath);
247
                        ra.DoWork();
248
                        ra.AddToScene(this.designAutoCAD);
249
                    }
250
                    catch(Exception ex)
251
                    {
252
                        RadMessageBox.Show(ex.Message, Globals.Name, MessageBoxButtons.OK, RadMessageIcon.Error);
253
                    }
254

  
255
                    var AddEntities = new List<Entity>();
256
                    this.designAutoCAD.Entities.ForEach(x =>
257
                    {
258
                        if (x is LinearPath lp)
259
                        {
260
                            int count = Convert.ToInt32(lp.Vertices.Length);
261
                            for (int i = 0; i < count - 1; ++i)
262
                            {
263
                                AddEntities.Add(new devDept.Eyeshot.Entities.Line(lp.Vertices[i], lp.Vertices[i + 1])
264
                                {
265
                                    LayerName = lp.LayerName,
266
                                    LineWeight = lp.LineWeight,
267
                                    LineTypeMethod = colorMethodType.byEntity
268
                                });
269
                            }
270
                        }
271
                        else if(x is BlockReference blkref && blkref.Attributes.Any())
272
                        {
273
                            var attributes = blkref.Attributes;
274
                            var entities = blkref.Explode(this.designAutoCAD.Blocks);
275
                            foreach(var ent in entities.Where(y => y is devDept.Eyeshot.Entities.Attribute))
276
                            {
277
                                var txt = ent as devDept.Eyeshot.Entities.Attribute;
278
                                KeyValuePair<string, AttributeReference>? kp = attributes.FirstOrDefault(z => z.Key == txt.TextString);
279
                                if (kp.HasValue) txt.TextString = kp.Value.Value.Value;
280
                            }
281

  
282
                            AddEntities.AddRange(entities.Where(y => (y is devDept.Eyeshot.Entities.Attribute) || (y is devDept.Eyeshot.Entities.Text)));
283
                            blkref.Attributes.Clear();
284
                        }
285
                    });
286

  
287
                    #region LinearPath 그리고 Except Layer에 있는 항목 제외
288
                    var ExceptLayers = Forms.ExceptLayer.ExceptLayerInfoColl.Select(x => x.Name);
289
                    this.designAutoCAD.Entities.RemoveAll(x => (x is LinearPath) || ExceptLayers.Contains(x.LayerName));
290
                    #endregion
291
                    this.designAutoCAD.Entities.AddRange(AddEntities);
292

  
293
                    #region 브랜치가 생성되는 부분에서 라인을 분할
294
                    var queue = this.designAutoCAD.Entities.Where(x => x is Line).ToList();
295
                    while(queue.Any())
296
                    {
297
                        var line1 = queue.First() as Line;
298
                        var dir1 = line1.Direction;
299
                        dir1.Normalize();
300
                        queue.Remove(line1);
301
                        for(int i = 0;i < queue.Count;++i)
302
                        {
303
                            var line2 = queue.ElementAt(i) as Line;
304
                            var dir2 = line2.Direction;
305
                            dir2.Normalize();
306
                            if(devDept.Geometry.Vector3D.AreOrthogonal(dir1, dir2))
307
                            {
308
                                var intersects = line1.IntersectWith(line2);
309
                                if(intersects.Count() == 1)
310
                                {
311
                                    if(line1.StartPoint.DistanceTo(intersects[0]) > 0.1 && line1.EndPoint.DistanceTo(intersects[0]) > 0.1)
312
                                    {
313
                                        var split1 = new devDept.Eyeshot.Entities.Line(line1.StartPoint, intersects[0])
314
                                        {
315
                                            LayerName = line1.LayerName,
316
                                            LineWeight = line1.LineWeight,
317
                                            LineTypeMethod = colorMethodType.byEntity
318
                                        };
319
                                        var split2 = new devDept.Eyeshot.Entities.Line(intersects[0], line1.EndPoint)
320
                                        {
321
                                            LayerName = line1.LayerName,
322
                                            LineWeight = line1.LineWeight,
323
                                            LineTypeMethod = colorMethodType.byEntity
324
                                        };
325
                                        this.designAutoCAD.Entities.Add(split1);
326
                                        this.designAutoCAD.Entities.Add(split2);
327
                                        this.designAutoCAD.Entities.Remove(line1);
328

  
329
                                        queue.Add(split1);
330
                                        queue.Add(split2);
331

  
332
                                        break;
333
                                    }
334

  
335
                                    if (line2.StartPoint.DistanceTo(intersects[0]) > 0.1 && line2.EndPoint.DistanceTo(intersects[0]) > 0.1)
336
                                    {
337
                                        var split1 = new devDept.Eyeshot.Entities.Line(line2.StartPoint, intersects[0])
338
                                        {
339
                                            LayerName = line2.LayerName,
340
                                            LineWeight = line2.LineWeight,
341
                                            LineTypeMethod = colorMethodType.byEntity
342
                                        };
343
                                        var split2 = new devDept.Eyeshot.Entities.Line(intersects[0], line2.EndPoint)
344
                                        {
345
                                            LayerName = line2.LayerName,
346
                                            LineWeight = line2.LineWeight,
347
                                            LineTypeMethod = colorMethodType.byEntity
348
                                        };
349
                                        this.designAutoCAD.Entities.Add(split1);
350
                                        this.designAutoCAD.Entities.Add(split2);
351
                                        this.designAutoCAD.Entities.Remove(line2);
352

  
353
                                        queue.Remove(line2);
354
                                        queue.Add(split1);
355
                                        queue.Add(split2);
356
                                    }
357
                                }
358
                            }
359
                        }
360
                    }
361
                    #endregion
362

  
363
                    ColorEntities(this.designAutoCAD, this.designAutoCAD.Entities, Verification.EqualColor);
364

  
365
                    // Sets the view as Top
366
                    this.designAutoCAD.SetView(viewType.Top);
367
                    this.designAutoCAD.ZoomFit();
368
                    this.designAutoCAD.Invalidate();
369
                }
370
            }
371

  
372
            /// AVEVA P&ID 파일을 화면에 표시한다.
373
            void ShowAVEVAPIDFile(string FilePath)
374
            {
375
                this.designAVEVA.Clear();
376
                if (System.IO.File.Exists(FilePath))
377
                {
378
                    devDept.Eyeshot.Translators.ReadAutodesk ra = new devDept.Eyeshot.Translators.ReadAutodesk(FilePath);
379
                    ra.DoWork();
380
                    ra.AddToScene(this.designAVEVA);
381

  
382
                    #region 멀티 라인들을 분할하여 추가한다.
383
                    var AddEntities = new List<Entity>();
384
                    this.designAVEVA.Entities.ForEach(x =>
385
                    {
386
                        if(x is Mesh mesh && (mesh.LayerName == "AS_PIPE" || mesh.LayerName == "AS_INST"))
387
                        {
388
                            int count = Convert.ToInt32(mesh.Vertices.Length * 0.5);
389
                            for (int i = 0;i < count - 1; ++i)
390
                            {
391
                                AddEntities.Add(new devDept.Eyeshot.Entities.Line(mesh.Vertices[i], mesh.Vertices[i + 1]) 
392
                                { 
393
                                    LayerName = mesh.LayerName,
394
                                    LineWeight = 3.0f,
395
                                    LineTypeMethod = colorMethodType.byEntity,
396
                                    Color = Verification.DiffColor,
397
                                    ColorMethod = colorMethodType.byEntity
398
                                });
399
                            }
400
                        }
401
                        else if (x is TabulatedSurface tf && (tf.LayerName == "AS_PIPE" || tf.LayerName == "AS_INST"))
402
                        {
403
                            int count = Convert.ToInt32(tf.ControlPoints.Length * 0.5);
404
                            for (int i = 0; i < count - 1; ++i)
405
                            {
406
                                AddEntities.Add(
407
                                    new devDept.Eyeshot.Entities.Line(
408
                                    new devDept.Geometry.Point3D(tf.ControlPoints[i, 0].X, tf.ControlPoints[i, 0].Y, 0),
409
                                    new devDept.Geometry.Point3D(tf.ControlPoints[i + 1, 0].X, tf.ControlPoints[i + 1, 0].Y, 0))
410
                                    {
411
                                        LayerName = tf.LayerName,
412
                                        LineWeight = 3.0f,
413
                                        LineTypeMethod = colorMethodType.byEntity,
414
                                        Color = Verification.DiffColor,
415
                                        ColorMethod = colorMethodType.byEntity
416
                                    }
417
                                );
418
                            }
419
                        }
420
                        else if (x is LinearPath lp)
421
                        {
422
                            int count = Convert.ToInt32(lp.Vertices.Length);
423
                            for (int i = 0; i < count - 1; ++i)
424
                            {
425
                                AddEntities.Add(new devDept.Eyeshot.Entities.Line(lp.Vertices[i], lp.Vertices[i + 1])
426
                                {
427
                                    LayerName = lp.LayerName,
428
                                    LineWeight = lp.LineWeight,
429
                                    LineTypeMethod = colorMethodType.byEntity
430
                                });
431
                            }
432
                        }
433
                    });
434
                    this.designAVEVA.Entities.RemoveAll(x => 
435
                    ((x is Mesh || x is TabulatedSurface) && (x.LayerName == "AS_PIPE" || x.LayerName == "AS_INST")) ||
436
                    (x is LinearPath));
437
                    this.designAVEVA.Entities.AddRange(AddEntities);
438
                    #endregion
439

  
440
                    ColorEntities(this.designAVEVA, this.designAVEVA.Entities, Verification.DiffColor);
441

  
442
                    #region 블럭 이름이 PSNODE, PENODE인 블럭은 보이지 않도록 한다.
443
                    this.designAVEVA.Entities.ForEach(x =>
444
                    {
445
                        if (x is BlockReference blkref && (blkref.BlockName == "PSNODE" || blkref.BlockName == "PENODE" || 
446
                        blkref.BlockName.StartsWith("ARROW")))
447
                            blkref.Visible = false;
448
                    });
449
                    #endregion
450

  
451
                    this.designAVEVA.SetView(viewType.Top);
452
                    this.designAVEVA.ZoomFit();
453
                    this.designAVEVA.Invalidate();
454
                }
455
            }
456

  
457
            if (this.radGridViewDocument.SelectedRows.Any() && this.radGridViewDocument.SelectedRows.First().DataBoundItem is Documents doc)
458
            {
459
                string dwgExtension = ".dwg";
460
                string ID2DrawingFolder = @"C:\Users\dsik13460.id\Documents\Projects\ID2.Manager\Docs";/// System.IO.Path.Combine(informations.FindID2LocalPath(doc.RefProjectCode), "drawings", "Native");
461
                string dwgFilePath = System.IO.Path.Combine(ID2DrawingFolder, $"{doc.DocumentNo}{dwgExtension}");
462
                this.radTextBoxID2DrawingFolder.Text = ID2DrawingFolder;
463

  
464
                ShowAutoCADFile(dwgFilePath); 
465
                string AVEVAPIDFolder = @"C:\Users\dsik13460.id\Documents\Projects\ID2.Manager\Docs\AVEVA";/// this.radBrowseEditorAVEVAPIDFolder.Value;
466
                string AVEVAPIDFilePath = string.Empty;
467
                if (AVEVAPIDFolder != null)
468
                {
469
                    AVEVAPIDFilePath = System.IO.Path.Combine(AVEVAPIDFolder, $"{doc.DocumentNo}{dwgExtension}");
470
                    ShowAVEVAPIDFile(AVEVAPIDFilePath);
471

  
472
                }
473

  
474
                if(System.IO.File.Exists(dwgFilePath) && System.IO.File.Exists(AVEVAPIDFilePath))
475
                {
476
                    CompareAndMark(this.designAutoCAD, this.designAutoCAD.Entities, this.designAVEVA, this.designAVEVA.Entities);
477
                }
478

  
479
                if(OnDocumentSelected != null) OnDocumentSelected(doc);
480
            }
481
        }
482

  
483
        public void DocumentListBinding(List<ID2.Manager.Data.Models.Documents> docs)
484
        {
485
            this.radGridViewDocument.FilterDescriptors.Clear();
486
            this.radGridViewDocument.DataSource = new BindingList<ID2.Manager.Data.Models.Documents>(docs);
487
        }
488

  
489
        /// <summary>
490
        /// 주어진 두 엔터티 리스트를 비교하여 틀린 엔터티의 색상을 Yellow로 변경한다.
491
        /// </summary>
492
        /// <param name="entList1"></param>
493
        /// <param name="entList2"></param>
494
        private void CompareAndMark(Design design1, IList<Entity> entList1, Design design2, IList<Entity> entList2)
495
        {
496
            int[] equalEntitiesInV1 = new int[entList2.Count];
497
            bool[] equalEntitiesInV2 = new bool[entList2.Count];
498

  
499
            /// 서로 검사 가능한 타입인지 확인한다.
500
            bool CheckType(Entity ent1, Entity ent2)
501
            {
502
                return ent1.GetType() == ent2.GetType() ||
503
                    (ent1.GetType() == typeof(devDept.Eyeshot.Entities.Text) && ent2.GetType() == typeof(devDept.Eyeshot.Entities.MultilineText)) ||
504
                    (ent1.GetType() == typeof(devDept.Eyeshot.Entities.MultilineText) && ent2.GetType() == typeof(devDept.Eyeshot.Entities.Text)) ||
505
                    (ent1.GetType() == typeof(devDept.Eyeshot.Entities.Line) && ent2.GetType() == typeof(devDept.Eyeshot.Entities.TabulatedSurface) ||
506
                    (ent1.GetType() == typeof(devDept.Eyeshot.Entities.Attribute) && ent2.GetType() == typeof(devDept.Eyeshot.Entities.Text)) ||
507
                    (ent1.GetType() == typeof(devDept.Eyeshot.Entities.Attribute) && ent2.GetType() == typeof(devDept.Eyeshot.Entities.MultilineText)));
508
            }
509

  
510
            try
511
            {
512
                for (int i = 0; i < entList1.Count(); i++)
513
                {
514
                    Entity entVp1 = entList1[i];
515
                    bool foundEqual = false;
516

  
517
                    for (int j = 0; j < entList2.Count(); j++)
518
                    {
519
                        Entity entVp2 = entList2[j];
520

  
521
                        if (entVp2 is BlockReference blkref && (blkref.BlockName == "PSNODE" || blkref.BlockName == "PENODE")) continue;
522
                        if (!equalEntitiesInV2[j] && CheckType(entVp1, entVp2) && 
523
                            CompareIfEqual(this.designAutoCAD, entVp1, this.designAVEVA, entVp2))
524
                        {
525
                            equalEntitiesInV1[j] = i;
526
                            equalEntitiesInV2[j] = true;
527
                            foundEqual = true;
528
                            break;
529
                        }
530
                    }
531
                    if (!foundEqual)
532
                    {
533
                        ColorEntity(design1, entList1[i], Verification.DiffColor, colorMethodType.byEntity, false);
534
                    }
535
                }
536

  
537
                for (int j = 0; j < entList2.Count; j++)
538
                {
539
                    if (equalEntitiesInV2[j])
540
                    {
541
                        ColorEntity(design2, entList2[j], Verification.EqualColor, colorMethodType.byEntity, false);
542
                    }
543
                }
544
            }
545
            catch(Exception ex)
546
            {
547
                Console.Write($"Error : {ex.Message}");
548
            }
549

  
550
            var bitmap1 = this.designAutoCAD.RenderToBitmap(new Size(2048, 1536));
551
            bitmap1.Save(@"c:\bitmap1.png", System.Drawing.Imaging.ImageFormat.Png);
552
            var bitmap2 = this.designAVEVA.RenderToBitmap(new Size(2048, 1536));
553
            bitmap2.Save(@"c:\bitmap2.png", System.Drawing.Imaging.ImageFormat.Png);
554

  
555
        }
556

  
557
        /// <summary>
558
        /// 주어진 두 엔터티를 비교한다.
559
        /// </summary>
560
        /// <param name="entVp1"></param>
561
        /// <param name="entVp2"></param>
562
        /// <returns></returns>
563
        private bool CompareIfEqual(Design design1, Entity entVp1, Design design2, Entity entVp2)
564
        {
565
            return AreEqual(design1, entVp1, design2, entVp2);
566
        }
567

  
568
        private bool CompareGEntityIfEqual(GEntity entVp1, GEntity entVp2)
569
        {
570
            return AreGEntityEqual(entVp1, entVp2);
571
        }
572

  
573
        /// <summary>
574
        /// 그래픽적으로 두 엔터티가 유사한지 검사한다.
575
        /// </summary>
576
        /// <param name="design1"></param>
577
        /// <param name="ent1"></param>
578
        /// <param name="design2"></param>
579
        /// <param name="ent2"></param>
580
        /// <returns></returns>
581
        private bool AreEqual(Design design1, Entity ent1, Design design2, Entity ent2)
582
        {
583
            if (ent1 is CompositeCurve cc1 && ent2 is CompositeCurve cc2)
584
            {
585
                if (cc1.CurveList.Count == cc2.CurveList.Count)
586
                {
587
                    int equalCurvesInListCount = 0;
588
                    foreach (var entC in cc1.CurveList)
589
                    {
590
                        foreach (var entC2 in cc2.CurveList)
591
                        {
592
                            if (entC.GetType() == entC2.GetType())
593
                            {
594
                                if (entC is Entity && entC2 is Entity && CompareIfEqual(design1, entC as Entity, design2, entC2 as Entity))
595
                                {
596
                                    equalCurvesInListCount++;
597
                                    break;
598
                                }
599
                                else if (entC is GEntity && entC2 is GEntity && CompareGEntityIfEqual(entC as GEntity, entC2 as GEntity))
600
                                {
601
                                    equalCurvesInListCount++;
602
                                    break;
603
                                }
604
                            }
605
                        }
606
                    }
607

  
608
                    if (cc1.CurveList.Count == equalCurvesInListCount)
609
                    {
610
                        return true;
611
                    }
612
                }
613
            }
614
            else if (ent1 is LinearPath lp1 && ent2 is LinearPath lp2)
615
            {
616
                if (lp1.Vertices.Length == lp2.Vertices.Length)
617
                {
618
                    for (int i = 0; i < lp1.Vertices.Length; i++)
619
                    {
620
                        if (lp1.Vertices[i].DistanceTo(lp2.Vertices[i]) > Verification.Tolerance)
621
                            return false;
622
                    }
623

  
624
                    return true;
625
                }
626
            }
627
            else if (ent1 is PlanarEntity pe1 && ent2 is PlanarEntity pe2)
628
            {
629
                if (ent1 is Arc arc1 && ent2 is Arc arc2)
630
                {
631
                    if (
632
                        arc1.Center.DistanceTo(arc2.Center) <= Verification.Tolerance &&
633
                        Math.Abs(arc1.Radius - arc2.Radius) <= Verification.Tolerance &&
634
                        Math.Abs(arc1.Domain.Min - arc2.Domain.Min) <= Verification.Tolerance &&
635
                        Math.Abs(arc1.Domain.Max - arc2.Domain.Max) <= Verification.Tolerance
636
                        )
637
                    {
638
                        return true;
639
                    }
640
                }
641
                else if (ent1 is Circle c1 && ent2 is Circle c2)
642
                {
643
                    if (
644
                        c1.Center.DistanceTo(c2.Center) <= Verification.Tolerance &&
645
                        Math.Abs(c1.Radius - c2.Radius) <= Verification.Tolerance
646
                        )
647
                    {
648
                        return true;
649
                    }
650
                }
651
                else if (ent1 is EllipticalArc e1 && ent2 is EllipticalArc e2)
652
                {
653
                    if (
654
                    	e1.Center.DistanceTo(e2.Center) <= Verification.Tolerance &&
655
                        Math.Abs(e1.RadiusX - e2.RadiusX) <= Verification.Tolerance &&
656
                        Math.Abs(e1.RadiusY - e2.RadiusY) <= Verification.Tolerance &&
657
                        Math.Abs(e1.Domain.Low - e2.Domain.Low) <= Verification.Tolerance &&
658
                        Math.Abs(e1.Domain.High - e2.Domain.High) <= Verification.Tolerance
659
                    )
660
                    {
661
                        return true;
662
                    }
663
                }
664
                else if (ent1 is Ellipse el1 && ent2 is Ellipse el2)
665
                {
666
                    if (
667
                        el1.Center.DistanceTo(el2.Center) <= Verification.Tolerance &&
668
                        Math.Abs(el1.RadiusX - el2.RadiusX) <= Verification.Tolerance &&
669
                        Math.Abs(el1.RadiusY - el2.RadiusY) <= Verification.Tolerance
670
                    )
671
                    {
672
                        return true;
673
                    }
674
                }
675
                #region 해치는 삽입점만 비교
676
                else if (ent1 is Hatch hatch1 && ent2 is Hatch hatch2)
... 이 차이점은 표시할 수 있는 최대 줄수를 초과해서 이 차이점은 잘렸습니다.

내보내기 Unified diff

클립보드 이미지 추가 (최대 크기: 500 MB)