프로젝트

일반

사용자정보

개정판 661b7416

ID661b7416598de29c8ba957a702c8b0b2135eda3f
상위 8c66babd
하위 5529d2a2

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

issue #999: Add FromString to all of controls

Change-Id: I64093e34a5f9e8d367cbed769ff4db8d7472cb7a

차이점 보기:

MarkupToPDF/Controls/Polygon/CloudControl.cs
14 14
using MarkupToPDF.Common;
15 15
using MarkupToPDF.Serialize.Core;
16 16
using MarkupToPDF.Serialize.S_Control;
17
using System.Linq;
17 18

  
18 19
namespace MarkupToPDF.Controls.Polygon
19 20
{
......
850 851
            }
851 852
        }
852 853

  
854
        /// <summary>
855
        /// create a cloudcontrol from given string
856
        /// </summary>
857
        /// <param name="str"></param>
858
        /// <returns></returns>
859
        public static CloudControl FromString(string str, SolidColorBrush brush, string sProjectNo)
860
        {
861
            CloudControl instance = null;
862
            using (S_CloudControl s = JsonSerializerHelper.JsonDeserialize<S_CloudControl>(str))
863
            {
864
                string[] data2 = s.SizeSet.Split(delimiterChars2, StringSplitOptions.RemoveEmptyEntries);
865
                instance = new CloudControl
866
                {
867
                    LineSize = Convert.ToDouble(data2.First()),
868
                    Toler = s.Toler,
869
                    PointSet = s.PointSet,
870
                    ArcLength = s.ArcLength,
871
                    Paint = s.PaintState,
872
                    Opacity = s.Opac,
873
                    StrokeColor = brush,
874
                    isTransOn = s.IsTrans,
875
                    isChain = s.IsChain,
876
                    DashSize = s.DashSize,
877
                    UserID = s.UserID,
878

  
879
                    StartPoint = s.StartPoint,
880
                    EndPoint = s.EndPoint,
881
                    Memo = s.Memo
882

  
883
                    //Fill = s.CloudFill,
884
                };
885
            }
886

  
887
            return instance;
888
        }
889

  
853 890
        #region Method
854 891
        public void ApplyOverViewData()
855 892
        {

내보내기 Unified diff

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