示例#1
0
        public IndicatorArrowProperty GetIndicatorProperty()
        {
            IndicatorArrowProperty iap = new IndicatorArrowProperty();

            iap.Antialias = this.Antialias;
            iap.LineColor = this.StrokeColor;
            iap.LineSize  = this.IndicatorLineSize;
            return(iap);
        }
示例#2
0
        public IndicatorArrowProperty Clone()
        {
            IndicatorArrowProperty iap = new IndicatorArrowProperty();

            iap.Antialias = this.Antialias;
            iap.LineColor = this.LineColor;
            iap.LineSize  = this.LineSize;
            return(iap);
        }
示例#3
0
 public IndicatorArrow(EPKernel container, IndicatorArrowProperty pro)
     : base(container, null)
 {
     _property = pro;
 }
示例#4
0
        private void CheckShapeProperty()
        {
            if (currentTool != ToolType.ShapeSelect || SelectedShapesCount != 1)
            {
                return;
            }

            bool         diff    = false;
            BaseProperty basepro = shapesList[selectedShapesIndexList[0]].ShapeProperty;

            if (proCollector.Antialias != basepro.Antialias)
            {
                proCollector.Antialias = basepro.Antialias;
                diff = true;
            }

            if (basepro is IndicatorArrowProperty)
            {
                IndicatorArrowProperty ip = (IndicatorArrowProperty)basepro;
                if (ip.LineColor != proCollector.StrokeColor ||
                    ip.LineSize != proCollector.IndicatorLineSize)
                {
                    diff = true;
                    proCollector.StrokeColor       = ip.LineColor;
                    proCollector.IndicatorLineSize = ip.LineSize;
                }
            }

            if (basepro is StrokableProperty)
            {
                StrokableProperty sp = (StrokableProperty)basepro;
                if (proCollector.PenWidth != sp.PenWidth ||
                    proCollector.StrokeColor != sp.StrokeColor ||
                    proCollector.LineDash != sp.LineDash ||
                    proCollector.StartLineCap != sp.StartLineCap ||
                    proCollector.EndLineCap != sp.EndLineCap ||
                    proCollector.PenAlign != sp.PenAlign ||
                    proCollector.HowLineJoin != sp.HowLineJoin)
                {
                    diff = true;
                    proCollector.PenWidth     = sp.PenWidth;
                    proCollector.StrokeColor  = sp.StrokeColor;
                    proCollector.LineDash     = sp.LineDash;
                    proCollector.StartLineCap = sp.StartLineCap;
                    proCollector.EndLineCap   = sp.EndLineCap;
                    proCollector.PenAlign     = sp.PenAlign;
                    proCollector.HowLineJoin  = sp.HowLineJoin;
                }
            }

            if (basepro is FillableProperty)
            {
                FillableProperty fp = (FillableProperty)basepro;
                if (proCollector.PaintType != fp.PaintType ||
                    proCollector.FillColor != fp.FillColor ||
                    proCollector.FillType != fp.FillType)
                {
                    diff = true;
                    proCollector.PaintType = fp.PaintType;
                    proCollector.FillColor = fp.FillColor;
                    proCollector.FillType  = fp.FillType;
                }
            }

            if (basepro is RoundedRectProperty)
            {
                RoundedRectProperty rp = (RoundedRectProperty)basepro;
                if (proCollector.RadiusAll != rp.RadiusAll)
                {
                    diff = true;
                    proCollector.RadiusAll = rp.RadiusAll;
                }
            }

            if (diff)
            {
                OnPropertyCollectorChanged(EventArgs.Empty);
            }
        }