コード例 #1
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            C1OutBar outBar = control as C1OutBar;

            outBar.PageTitleHeight = infos.Zoom(outBar.PageTitleHeight);
            base.ZoomBounds(control, infos);
        }
コード例 #2
0
 private void ZoomChartView(ZoomBoundsInfo infos, Chart3DView view)
 {
     if (view == null)
     {
         return;
     }
 }
コード例 #3
0
 private void ZoomChartGroups(ZoomBoundsInfo infos, Chart3DGroups groups)
 {
     if (groups == null)
     {
         return;
     }
     foreach (Chart3DStyle style in groups.ChartStyles)
     {
         ZoomChart3DStyle(infos, style);
     }
     foreach (Chart3DContourStyle style in groups.ContourStyles.Styles)
     {
         ZoomContourStyles(infos, style);
     }
     foreach (Chart3DGroup group in groups.ChartGroupsCollection)
     {
         if (group.Contour != null)
         {
             foreach (Chart3DContourLevel level in group.Contour.Levels)
             {
                 ZoomContourStyles(infos, level.Style);
             }
         }
         if (group.ChartData.SetPoint != null)
         {
             foreach (Chart3DPointSeries series in group.ChartData.SetPoint.SeriesCollection)
             {
                 ZoomDataSeries(infos, series);
             }
         }
     }
 }
コード例 #4
0
 private void ZoomPlotArea(ZoomBoundsInfo infos, PlotArea plotArea)
 {
     if (plotArea == null)
     {
         return;
     }
     if (plotArea.LocationDefault.X > 0 || plotArea.LocationDefault.Y > 0)
     {
         plotArea.LocationDefault = ZoomPoint(infos, plotArea.LocationDefault);
     }
     if (plotArea.SizeDefault.Width > 0 || plotArea.SizeDefault.Height > 0)
     {
         plotArea.SizeDefault = ZoomSize(infos, plotArea.SizeDefault);
     }
     foreach (AlarmZone alarmZone in plotArea.AlarmZones)
     {
         if (alarmZone.MinHeight > 0)
         {
             alarmZone.MinHeight = infos.Zoom(alarmZone.MinHeight);
         }
         if (alarmZone.MinWidth > 0)
         {
             alarmZone.MinWidth = infos.Zoom(alarmZone.MinWidth);
         }
     }
 }
コード例 #5
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            MyImageButton imageBUtton = control as MyImageButton;

            imageBUtton.ImageFactor = infos.TargetFactor;
            base.ZoomBounds(control, infos);
        }
コード例 #6
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            C1BarCode barcode = control as C1BarCode;

            barcode.ModuleSize = infos.Zoom(barcode.ModuleSize);
            barcode.BarHeight  = infos.Zoom(barcode.BarHeight);
            base.ZoomBounds(control, infos);
        }
コード例 #7
0
 private void ZoomChart3DStyle(ZoomBoundsInfo infos, Chart3DStyle Style)
 {
     if (Style.SymbolStyle.Size > 0)
     {
         Style.SymbolStyle.Size = infos.Zoom(Style.SymbolStyle.Size);
     }
     Style.LineStyle.Thickness = infos.Zoom(Style.LineStyle.Thickness);
 }
コード例 #8
0
 private void ZoomDataSeries(ZoomBoundsInfo infos, Chart3DPointSeries dataSeries)
 {
     if (dataSeries == null)
     {
         return;
     }
     ZoomChart3DStyle(infos, dataSeries.Style);
 }
コード例 #9
0
 private void ZoomContourStyles(ZoomBoundsInfo infos, Chart3DContourStyle style)
 {
     if (style.LineStyle.Thickness > 0 &&
         !_zoomedContourStyles.Contains(style))
     {
         style.LineStyle.Thickness = infos.Zoom(style.LineStyle.Thickness);
         _zoomedContourStyles.Add(style);
     }
 }
コード例 #10
0
        private Point ZoomPoint(ZoomBoundsInfo infos, Point point)
        {
            int x = point.X;
            int y = point.Y;

            x = x > 0 ? infos.Zoom(x) : x;
            y = y > 0 ? infos.Zoom(y) : y;
            return(new Point(x, y));
        }
コード例 #11
0
 private void ZoomLineStyle(ZoomBoundsInfo infos, ChartLineStyle lineStyle)
 {
     if (lineStyle.Thickness > 0 &&
         !_zoomedLineStyles.Contains(lineStyle))
     {
         lineStyle.Thickness = infos.Zoom(lineStyle.Thickness);
         _zoomedLineStyles.Add(lineStyle);
     }
 }
コード例 #12
0
 private void ZoomSymbolStyle(ZoomBoundsInfo infos, ChartSymbolStyle symbolStyle)
 {
     if (symbolStyle.Size > 0 &&
         !_zoomedSymbolStyle.Contains(symbolStyle))
     {
         symbolStyle.Size = infos.Zoom(symbolStyle.Size);
         _zoomedSymbolStyle.Add(symbolStyle);
     }
 }
コード例 #13
0
        private static Size ZoomSize(ZoomBoundsInfo infos, Size size)
        {
            int width  = size.Width;
            int height = size.Height;

            width  = width > 0 ? infos.Zoom(width) : width;
            height = height > 0 ? infos.Zoom(height) : height;
            return(new Size(width, height));
        }
コード例 #14
0
 private void ZoomDataSeries(ZoomBoundsInfo infos, ChartDataSeries dataSeries)
 {
     if (dataSeries == null)
     {
         return;
     }
     ZoomSymbolStyle(infos, dataSeries.SymbolStyle);
     ZoomLineStyle(infos, dataSeries.LineStyle);
 }
コード例 #15
0
 private void ZoomChartLabels(ZoomBoundsInfo infos, ChartLabels labels)
 {
     if (labels == null)
     {
         return;
     }
     foreach (Label label in labels.LabelsCollection)
     {
         ZoomChartLabel(infos, label);
     }
 }
コード例 #16
0
 private void ZoomAxis(ZoomBoundsInfo infos, Chart3DAxis axis)
 {
     if (axis == null)
     {
         return;
     }
     if (axis.MajorGrid.Style.Thickness > 0)
     {
         axis.MajorGrid.Style.Thickness = infos.Zoom(axis.MajorGrid.Style.Thickness);
     }
 }
コード例 #17
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            base.ZoomBounds(control, infos);
            C1Schedule schedule = control as C1Schedule;

            if (schedule.AppointmentHeight > 0)
            {
                schedule.AppointmentHeight = infos.Zoom(schedule.AppointmentHeight);
            }
            control.Refresh();
        }
コード例 #18
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            C1InputPanel ip = control as C1InputPanel;

            if (ip != null)
            {
                ip.UpdateFontZoom(infos.TargetFactor, false);
                float k = infos.TargetFactor / infos.CurrentFactor;
                control.Scale(new SizeF(k, k));
            }
        }
コード例 #19
0
        public override void ZoomBounds(System.Windows.Forms.Control control, ZoomBoundsInfo infos)
        {
            var previewPane = control as C1PreviewPane;

            if (previewPane.ZoomMode == ZoomModeEnum.Custom ||
                previewPane.ZoomMode == ZoomModeEnum.ActualSize)
            {
                previewPane.ZoomFactor = infos.Zoom(previewPane.ZoomFactor);
            }

            base.ZoomBounds(control, infos);
        }
コード例 #20
0
 private void ZoomCommandLinksBounds(ZoomBoundsInfo infos, C1CommandLinks commandLinks)
 {
     foreach (C1CommandLink commandLink in commandLinks)
     {
         if (commandLink.Command is C1CommandMenu)
         {
             C1CommandMenu commandMenu = commandLink.Command as C1CommandMenu;
             ZoomCommandLinksBounds(infos, commandMenu.CommandLinks);
             return;
         }
     }
 }
コード例 #21
0
        public override void ZoomBounds(System.Windows.Forms.Control control, ZoomBoundsInfo infos)
        {
            C1Chart chart = control as C1Chart;

            ZoomChartGroups(infos, chart.ChartGroups);
            ZoomChartArea(infos, chart.ChartArea);
            ZoomTitle(infos, chart.Header);
            ZoomTitle(infos, chart.Footer);
            ZoomLegend(infos, chart.Legend);
            ZoomChartLabels(infos, chart.ChartLabels);
            base.ZoomBounds(control, infos);
        }
コード例 #22
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            var size = control.MaximumSize;

            // Change the MaxSize to make sure the Size can be changed.
            control.MaximumSize = new Size(control.Width, control.Height);

            base.ZoomBounds(control, infos);

            control.MaximumSize = infos.Zoom(size);

            control.Refresh();
        }
コード例 #23
0
 private void ZoomAxis(ZoomBoundsInfo infos, Axis axis)
 {
     if (axis == null)
     {
         return;
     }
     axis.Thickness = infos.Zoom(axis.Thickness);
     foreach (ValueLabel valueLabel in axis.ValueLabels)
     {
         if (valueLabel.MarkerSize > 0)
         {
             valueLabel.MarkerSize = infos.Zoom(valueLabel.MarkerSize);
         }
     }
 }
コード例 #24
0
 private void ZoomTitle(ZoomBoundsInfo infos, Title title)
 {
     if (title == null)
     {
         return;
     }
     if (title.LocationDefault.X > 0 || title.LocationDefault.Y > 0)
     {
         title.LocationDefault = ZoomPoint(infos, title.LocationDefault);
     }
     if (title.SizeDefault.Width > 0 || title.SizeDefault.Height > 0)
     {
         title.SizeDefault = ZoomSize(infos, title.SizeDefault);
     }
 }
コード例 #25
0
 private void ZoomLegend(ZoomBoundsInfo infos, Legend legend)
 {
     if (legend == null)
     {
         return;
     }
     if (legend.LocationDefault.X > 0 || legend.LocationDefault.Y > 0)
     {
         legend.LocationDefault = ZoomPoint(infos, legend.LocationDefault);
     }
     if (legend.SizeDefault.Width > 0 || legend.SizeDefault.Height > 0)
     {
         legend.SizeDefault = ZoomSize(infos, legend.SizeDefault);
     }
 }
コード例 #26
0
 private void ZoomChartGroups(ZoomBoundsInfo infos, ChartGroups groups)
 {
     if (groups == null)
     {
         return;
     }
     foreach (ChartGroup group in groups.ChartGroupsCollection)
     {
         foreach (FunctionBase functionBase in group.ChartData.FunctionsList)
         {
             ZoomLineStyle(infos, functionBase.LineStyle);
         }
         foreach (ChartDataSeries series in group.ChartData.SeriesList)
         {
             ZoomDataSeries(infos, series);
         }
     }
 }
コード例 #27
0
        public override void ZoomBounds(System.Windows.Forms.Control control, ZoomBoundsInfo infos)
        {
            C1FlexGrid flexGrid = control as C1FlexGrid;

            flexGrid.Cols.DefaultSize = infos.Zoom(_flexGridInfoCache[control].DefaultColSize);
            flexGrid.Rows.DefaultSize = infos.Zoom(_flexGridInfoCache[control].DefaultRowSize);
            if (flexGrid.Rows.MinSize > 0)
            {
                flexGrid.Rows.MinSize = infos.Zoom(flexGrid.Rows.MinSize);
            }
            if (flexGrid.Cols.MinSize > 0)
            {
                flexGrid.Cols.MinSize = infos.Zoom(flexGrid.Cols.MinSize);
            }

            if (!_zoomedCols.ContainsKey(flexGrid.Cols))
            {
                // The columns may be shared by multi flex grid.
                _zoomedCols.Add(flexGrid.Cols, null);
                foreach (Column column in flexGrid.Cols)
                {
                    if (column.Width > 0)
                    {
                        column.Width = infos.Zoom(column.Width);
                    }
                }
            }

            if (!_zoomedCols.ContainsKey(flexGrid.Rows))
            {
                // The rows may be shared by multi flex grid.
                _zoomedCols.Add(flexGrid.Rows, null);
                foreach (Row row in flexGrid.Rows)
                {
                    if (row.Height > 0)
                    {
                        row.Height = infos.Zoom(row.Height);
                    }
                }
            }

            base.ZoomBounds(control, infos);
        }
コード例 #28
0
        public override void ZoomBounds(Control control, ZoomBoundsInfo infos)
        {
            base.ZoomBounds(control, infos);
            C1DockingTab dockingTab = control as C1DockingTab;

            try
            {
                dockingTab.ItemSize = infos.Zoom(dockingTab.ItemSize);
            }
            catch (Exception)
            {
                // When the docking tab is collapse, set ItemSize property may throw exception.
                // If this case occurs, set the ItemSize to Size.Empty as a workaround.
                dockingTab.ItemSize = Size.Empty;
            }
            dockingTab.SplitterWidth  = infos.Zoom(dockingTab.SplitterWidth);
            dockingTab.TabsSpacing    = infos.Zoom(dockingTab.TabsSpacing);
            dockingTab.TabAreaSpacing = infos.Zoom(dockingTab.TabAreaSpacing);
        }
コード例 #29
0
 private void ZoomChartLabel(ZoomBoundsInfo infos, Label label)
 {
     if (label == null)
     {
         return;
     }
     if (label.AttachMethodData.X > 0 || label.AttachMethodData.Y > 0)
     {
         double x = label.AttachMethodData.X;
         double y = label.AttachMethodData.Y;
         x = x > 0 ? infos.Zoom(x) : x;
         y = y > 0 ? infos.Zoom(y) : y;
         label.AttachMethodData.X = x;
         label.AttachMethodData.Y = y;
     }
     if (label.SizeDefault.Width > 0 || label.SizeDefault.Height > 0)
     {
         label.SizeDefault = ZoomSize(infos, label.SizeDefault);
     }
 }
コード例 #30
0
 private void ZoomChartArea(ZoomBoundsInfo infos, Area area)
 {
     if (area == null)
     {
         return;
     }
     foreach (Axis axis in area.Axes)
     {
         ZoomAxis(infos, axis);
     }
     ZoomPlotArea(infos, area.PlotArea);
     if (area.LocationDefault.X > 0 || area.LocationDefault.Y > 0)
     {
         area.LocationDefault = ZoomPoint(infos, area.LocationDefault);
     }
     if (area.SizeDefault.Width > 0 || area.SizeDefault.Height > 0)
     {
         area.SizeDefault = ZoomSize(infos, area.SizeDefault);
     }
 }