Exemplo n.º 1
0
 public void Update(ExControl i_Control, int left, int right, int top, int bottom)
 {
     _CtrlBounds = i_Control.XtraContainer.Bounds;
     _Left       = left;
     _Right      = right;
     _Top        = Math.Max(top, _Top);
     _Bottom     = Math.Max(bottom, _Bottom);
 }
        public MaskedTextControlView(Webb.Reports.ExControls.ExControl i_Control) : base(i_Control)
        {
            this._MaskInfoSetting = new MaskInfoCollection();

            this._MaskInfoSetting.Add(new MaskInfo());

            this._RowsHight    = new Int32Collection();
            this._ColumnsWidth = new Int32Collection();
        }
Exemplo n.º 3
0
 public bool HasContainControl(ExControl control)
 {
     foreach (RepeatControl R_Control in this)
     {
         if (R_Control.HasContain(control))
         {
             return(true);
         }
     }
     return(false);
 }
Exemplo n.º 4
0
        public void UpdateLineInfo(ExControl i_Control, bool iNewLine)
        {
            foreach (RectInfo rectInfo in this)
            {
                if (!rectInfo.Contains(i_Control))
                {
                    continue;
                }

                rectInfo.UpdateLineInfo(i_Control, iNewLine);
            }
        }
Exemplo n.º 5
0
        public void UpdatePrintInfo(ExControl i_Control, int left, int right, int top, int bottom)
        {
            foreach (RectInfo rectInfo in this)
            {
                if (!rectInfo.Contains(i_Control))
                {
                    continue;
                }

                rectInfo.UpdatePrintInfo(i_Control, left, right, top, bottom);
            }
        }
Exemplo n.º 6
0
        public int Indexof(ExControl m_Control)
        {
            for (int i = 0; i < this.Count; i++)
            {
                if (this[i].Contains(m_Control))
                {
                    return(i);
                }
            }

            return(-1);
        }
Exemplo n.º 7
0
        public void UpdateLineInfo(ExControl m_Control, bool iNewLine)
        {
            if (iNewLine)
            {
                _LinePrintInfo.LastLineCtrlBottom = _LinePrintInfo.LineCtrlBottom;

                _LinePrintInfo.LineCtrlBottom = m_Control.XtraContainer.Bottom;
            }
            else
            {
                _LinePrintInfo.LineCtrlBottom = Math.Max(m_Control.XtraContainer.Bottom, _LinePrintInfo.LineCtrlBottom);;
            }
        }
Exemplo n.º 8
0
        public bool Contains(ExControl control)
        {
            Rectangle ctrlRect = control.XtraContainer.Bounds;

            if (ctrlRect.Left < _Rect.Left || ctrlRect.Right > _Rect.Right)
            {
                return(false);
            }

            if (ctrlRect.Top < _Rect.Top || ctrlRect.Bottom > _Rect.Bottom)
            {
                return(false);
            }

            return(true);
        }
Exemplo n.º 9
0
        public bool HasContain(ExControl control)
        {
            Rectangle ctrlRect = control.XtraContainer.Bounds;

            if (ctrlRect.Left < this.XtraContainer.Left || ctrlRect.Right > XtraContainer.Right)
            {
                return(false);
            }

            if (ctrlRect.Top < XtraContainer.Top || ctrlRect.Bottom > XtraContainer.Bottom)
            {
                return(false);
            }

            return(true);
        }
Exemplo n.º 10
0
 public ExControlHelper(ExControl owner) : base(owner)
 {
 }
Exemplo n.º 11
0
 public void UpdatePrintInfo(ExControl i_Control, int left, int right, int top, int bottom)
 {
     _LastRect.Update(i_Control, left, right, top, bottom);
 }
Exemplo n.º 12
0
        public void Init(WinControlContainerCollection wincontrols)
        {
            this.InnerList.Clear();

            foreach (DevExpress.XtraReports.UI.WinControlContainer m_Container in WebbReport.ExControls)
            {
                RepeatControl m_Control = m_Container.WinControl as RepeatControl;

                if (m_Control == null || this.HasContainControl(m_Control))
                {
                    continue;
                }

                this.InnerList.Add(m_Control);
            }

            foreach (RepeatControl control in this)
            {
                float maxValue = -1;

                control.SubControls.Clear();

                control.SubShapeContainers.Clear();

                foreach (DevExpress.XtraReports.UI.WinControlContainer winControl in WebbReport.ExControls)
                {
                    ExControl m_Control = winControl.WinControl as ExControl;

                    if (m_Control == null || !control.HasContain(m_Control) || m_Control is RepeatControl)
                    {
                        continue;
                    }

                    if ((m_Control is ExShapeControl) && (m_Control as ExShapeControl).AutoFit)
                    {
                        control.SubShapeContainers.Add(new RectInfo(m_Control as ExShapeControl));
                    }
                    else
                    {
                        control.SubControls.Add(m_Control);

                        if (m_Control is ChartControlEx && !m_Control.Repeat)
                        {
                            ChartControlEx chartControl = m_Control as ChartControlEx;

                            chartControl.MaxValuesWhenTop = -1;

                            float maxchartValue = chartControl.GetMaxDatapoint();

                            maxValue = Math.Max(maxchartValue, maxValue);
                        }
                    }
                }
                if (maxValue < 0)
                {
                    continue;
                }

                foreach (ExControl m_Control in control.SubControls)
                {
                    if (!(m_Control is ChartControlEx) || m_Control.Repeat)
                    {
                        continue;
                    }

                    (m_Control as ChartControlEx).MaxValuesWhenTop = maxValue;
                }
            }
        }