Exemple #1
0
        internal static void GenerateScaleBreakVisibleLabels(NumericalAxis axis, object actualInterval, double smallTicksPerInterval)
        {
            var ranges = axis != null ? axis.AxisRanges : null;

            if (ranges == null || ranges.Count == 0)
            {
                GenerateVisibleLabels(axis, axis.Minimum, axis.Maximum, axis.Interval, axis.SmallTicksPerInterval);
            }
            else
            {
                for (int i = 0; i < ranges.Count; i++)
                {
                    var position = ranges[i].Start;
                    var interval = axis.CalculateActualInterval(
                        ranges[i],
                        axis.Orientation == Orientation.Vertical
                        ? new Size(axis.AvailableSize.Width, axis.AxisLength[i])
                            : new Size(axis.AxisLength[i], axis.AvailableSize.Height));

                    if (!ranges[i].Inside(position))
                    {
                        continue;
                    }

                    for (; position <= ranges[i].End; position += interval)
                    {
                        axis.VisibleLabels.Add(new ChartAxisLabel(position, axis.GetActualLabelContent(position), position));
                        if (ranges[i].Delta == 0)
                        {
                            break;
                        }
                        if (axis.smallTicksRequired)
                        {
                            axis.AddSmallTicksPoint(position, interval);
                        }
                    }

                    if (ranges[i].End.Equals(position - interval))
                    {
                        continue;
                    }
                    var count     = axis.VisibleLabels.Count;
                    var lastLabel = new ChartAxisLabel();
                    lastLabel.Position     = ranges[i].End;
                    lastLabel.LabelContent = axis.GetActualLabelContent(ranges[i].End);
                    if (Convert.ToDouble(axis.VisibleLabels[count - 1].LabelContent) != ranges[i].End)
                    {
                        axis.VisibleLabels.Add(lastLabel);
                    }
                }
            }
        }
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.lineChart = ((Syncfusion.UI.Xaml.Charts.SfChart)(target));
                return;

            case 2:
                this.DonViBieuDo = ((Syncfusion.UI.Xaml.Charts.NumericalAxis)(target));
                return;
            }
            this._contentLoaded = true;
        }
Exemple #3
0
        protected override DependencyObject CloneAxis(DependencyObject obj)
        {
            var numericalAxis = new NumericalAxis();

            numericalAxis.Minimum            = this.Minimum;
            numericalAxis.Maximum            = this.Maximum;
            numericalAxis.StartRangeFromZero = this.StartRangeFromZero;
            numericalAxis.Interval           = this.Interval;
            numericalAxis.RangePadding       = this.RangePadding;
            foreach (ChartAxisScaleBreak scaleBreak in AxisScaleBreaks)
            {
                numericalAxis.AxisScaleBreaks.Add((ChartAxisScaleBreak)scaleBreak.Clone());
            }

            obj = numericalAxis;
            return(base.CloneAxis(obj));
        }
        protected async override void OnNavigatedTo(NavigationEventArgs e)
        {
            ResultCollection = new ObservableCollection<WiFiNetworkDisplay>();
            var result = await Windows.Devices.Enumeration.DeviceInformation.FindAllAsync(WiFiAdapter.GetDeviceSelector());
            if (result.Count >= 1)
            {
                firstAdapter = await WiFiAdapter.FromIdAsync(result[0].Id);
            }
            foreach (var network in firstAdapter.NetworkReport.AvailableNetworks)
            {
                var networkDisplay = new WiFiNetworkDisplay(network, firstAdapter);
                await networkDisplay.UpdateConnectivityLevel();
                ResultCollection.Add(networkDisplay);
            }

            // sfdgNetList.DataContext = WiFiScan.WiFiNetworkDisplay;
            sfdgNetList.AllowSorting = true;
            sfdgNetList.AllowFiltering = true;
            sfdgNetList.RowHeight = 13;
   


            sfdgNetList.HeaderRowHeight = 30;
            sfdgNetList.AutoGenerateColumns = false;
            sfdgNetList.ItemsSource = ResultCollection;
            sfdgNetList.ColumnSizer = Syncfusion.UI.Xaml.Grid.GridLengthUnitType.Auto;
            sfdgNetList.Columns.Add(new GridTextColumn() { HeaderText = "SSID", MappingName = "Ssid" });
            sfdgNetList.Columns.Add(new GridTextColumn() { HeaderText = "BSSID", MappingName = "Bssid" });
            sfdgNetList.Columns.Add(new GridTextColumn() { HeaderText = "Channel", MappingName = "Channel" });
            sfdgNetList.Columns.Add(new GridTextColumn() { HeaderText = "RSSI", MappingName = "Rssi" });
            sfdgNetList.Columns.Add(new GridTextColumn() { HeaderText = "Security", MappingName = "SecuritySettings" });


            //Chart Stuff
            sfChartNetView24.Header = "Wi-Fi Networks";
            NumericalAxis primaryAxis = new Syncfusion.UI.Xaml.Charts.NumericalAxis();
            primaryAxis.Minimum = 0;
            primaryAxis.Maximum = 14;
            primaryAxis.Interval = 1;

            primaryAxis.Header = "Channels";

            sfChartNetView24.PrimaryAxis = primaryAxis;
            NumericalAxis SecondaryNumericalAxis = new Syncfusion.UI.Xaml.Charts.NumericalAxis();
            SecondaryNumericalAxis.Header = "Signal Strength";
            SecondaryNumericalAxis.Minimum = -100;
            SecondaryNumericalAxis.Maximum = -15;
            SecondaryNumericalAxis.Interval = 10;
            sfChartNetView24.SecondaryAxis = SecondaryNumericalAxis;

            ChartSeriesInput = new ObservableCollection<ChartHelperBssidNodeSeries>();
            ChartSeriesInput = HelperFunctions.ChartHelper(ResultCollection);

            foreach (ChartHelperBssidNodeSeries c in ChartSeriesInput)
            {

                SplineSeries mySeries = new SplineSeries();
                mySeries.ItemsSource = c.Series;
                mySeries.Label = "Home";
                mySeries.XBindingPath = "Channel";
                mySeries.YBindingPath = "Rssi";
                mySeries.StrokeThickness = 2;
                //mySeries.EnableAnimation = true;
                //mySeries.AnimationDuration = System.TimeSpan.FromSeconds(.2);
                sfChartNetView24.Series.Add(mySeries);

            }

            //Chart Stuff
            sfChartNetView52.Header = "Wi-Fi Networks";
            NumericalAxis primaryAxis52 = new Syncfusion.UI.Xaml.Charts.NumericalAxis();
            primaryAxis52.Minimum = 36;
            primaryAxis52.Maximum = 165;
            primaryAxis52.Interval = 2;
            primaryAxis52.IsTextScaleFactorEnabled = true;
            primaryAxis52.LabelsIntersectAction = AxisLabelsIntersectAction.Hide;
            primaryAxis.Header = "Channels";

            sfChartNetView52.PrimaryAxis = primaryAxis52;
            NumericalAxis SecondaryNumericalAxis52 = new Syncfusion.UI.Xaml.Charts.NumericalAxis();
            SecondaryNumericalAxis52.Header = "Signal Strength";
            SecondaryNumericalAxis52.Minimum = -100;
            SecondaryNumericalAxis52.Maximum = -15;
            SecondaryNumericalAxis52.Interval = 10;
            sfChartNetView24.SecondaryAxis = SecondaryNumericalAxis52;

            ChartSeriesInput = new ObservableCollection<ChartHelperBssidNodeSeries>();
            ChartSeriesInput = HelperFunctions.ChartHelper(ResultCollection);

            foreach (ChartHelperBssidNodeSeries c in ChartSeriesInput)
            {

                SplineSeries mySeries = new SplineSeries();
                mySeries.ItemsSource = c.Series;
                mySeries.Label = "Home";
                mySeries.XBindingPath = "Channel";
                mySeries.YBindingPath = "Rssi";
                mySeries.StrokeThickness = 2;
                //mySeries.EnableAnimation = true;
                //mySeries.AnimationDuration = System.TimeSpan.FromSeconds(.2);
                sfChartNetView52.Series.Add(mySeries);

            }

        }
Exemple #5
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:
                this.symbolBox = ((Telerik.Windows.Controls.RadAutoCompleteBox)(target));
                return;

            case 2:
                this.dpStart = ((System.Windows.Controls.DatePicker)(target));

            #line 22 "..\..\MainWindow.xaml"
                this.dpStart.SelectedDateChanged += new System.EventHandler <System.Windows.Controls.SelectionChangedEventArgs>(this.dpStart_SelectedDateChanged);

            #line default
            #line hidden
                return;

            case 3:
                this.dpExpiration = ((System.Windows.Controls.DatePicker)(target));

            #line 32 "..\..\MainWindow.xaml"
                this.dpExpiration.SelectedDateChanged += new System.EventHandler <System.Windows.Controls.SelectionChangedEventArgs>(this.dpExpiration_SelectedDateChanged);

            #line default
            #line hidden
                return;

            case 4:
                this.mainChart = ((Syncfusion.UI.Xaml.Charts.SfChart)(target));
                return;

            case 5:
                this.primaryMain = ((Syncfusion.UI.Xaml.Charts.DateTimeCategoryAxis)(target));
                return;

            case 6:
                this.secondaryMain = ((Syncfusion.UI.Xaml.Charts.NumericalAxis)(target));
                return;

            case 7:
                this.navigator = ((Syncfusion.UI.Xaml.Charts.SfDateTimeRangeNavigator)(target));
                return;

            case 8:
                this.navigatorChart = ((Syncfusion.UI.Xaml.Charts.SfLineSparkline)(target));
                return;

            case 9:
                this.lblInfo = ((System.Windows.Controls.TextBlock)(target));
                return;

            case 10:
                this.btnQuery = ((System.Windows.Controls.Button)(target));

            #line 78 "..\..\MainWindow.xaml"
                this.btnQuery.Click += new System.Windows.RoutedEventHandler(this.btnQuery_Click);

            #line default
            #line hidden
                return;

            case 11:
                this.btnQueryPercent = ((System.Windows.Controls.Button)(target));

            #line 79 "..\..\MainWindow.xaml"
                this.btnQueryPercent.Click += new System.Windows.RoutedEventHandler(this.btnQueryPrice_Click);

            #line default
            #line hidden
                return;
            }
            this._contentLoaded = true;
        }
Exemple #6
0
        void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target)
        {
            switch (connectionId)
            {
            case 1:

            #line 28 "..\..\..\Pages\Report.xaml"
                ((System.Windows.Controls.Primitives.RepeatButton)(target)).Click += new System.Windows.RoutedEventHandler(this.RepeatButton_Click_1);

            #line default
            #line hidden
                return;

            case 2:

            #line 36 "..\..\..\Pages\Report.xaml"
                ((System.Windows.Controls.Primitives.RepeatButton)(target)).Click += new System.Windows.RoutedEventHandler(this.RepeatButton_Click);

            #line default
            #line hidden
                return;

            case 3:
                this.WindowScroll = ((System.Windows.Controls.ScrollViewer)(target));
                return;

            case 4:

            #line 108 "..\..\..\Pages\Report.xaml"
                ((System.Windows.Controls.Button)(target)).Click += new System.Windows.RoutedEventHandler(this.Button_Click);

            #line default
            #line hidden
                return;

            case 5:
                this.OrderDetails = ((System.Windows.Controls.Grid)(target));
                return;

            case 6:
                this.Details = ((System.Windows.Controls.Grid)(target));
                return;

            case 7:
                this.FondSumm = ((System.Windows.Controls.DockPanel)(target));
                return;

            case 8:
                this.RecomendPort = ((System.Windows.Controls.Grid)(target));
                return;

            case 9:
                this.CurrentPortfel = ((System.Windows.Controls.Grid)(target));
                return;

            case 10:
                this.cInner = ((Syncfusion.UI.Xaml.Charts.SfChart)(target));
                return;

            case 11:
                this.sInner = ((Syncfusion.UI.Xaml.Charts.PieSeries)(target));
                return;

            case 12:
                this.cMidder = ((Syncfusion.UI.Xaml.Charts.SfChart)(target));
                return;

            case 13:
                this.doughnutSeries2 = ((Syncfusion.UI.Xaml.Charts.DoughnutSeries)(target));
                return;

            case 14:
                this.vvv = ((Syncfusion.UI.Xaml.Charts.ChartAdornmentInfo)(target));
                return;

            case 15:
                this.cOuter = ((Syncfusion.UI.Xaml.Charts.SfChart)(target));
                return;

            case 16:
                this.doughnutSeries3 = ((Syncfusion.UI.Xaml.Charts.DoughnutSeries)(target));
                return;

            case 17:
                this.Legeng = ((System.Windows.Controls.Grid)(target));
                return;

            case 18:
                this.iLegend = ((System.Windows.Controls.ItemsControl)(target));
                return;

            case 19:
                this.Moreinformation = ((System.Windows.Controls.Grid)(target));
                return;

            case 20:
                this.InvestDetails = ((System.Windows.Controls.DockPanel)(target));
                return;

            case 21:
                this.Chart = ((System.Windows.Controls.Grid)(target));
                return;

            case 22:
                this.actives = ((System.Windows.Controls.Grid)(target));
                return;

            case 23:
                this.TTT = ((Syncfusion.UI.Xaml.Charts.NumericalAxis)(target));
                return;

            case 24:
                this.dynamic = ((System.Windows.Controls.Grid)(target));
                return;

            case 25:
                this.CalendarFrom = ((System.Windows.Controls.Calendar)(target));
                return;

            case 26:
                this.CalendarTo = ((System.Windows.Controls.Calendar)(target));
                return;

            case 27:
                this.m1 = ((System.Windows.Controls.Button)(target));
                return;

            case 28:
                this.m3 = ((System.Windows.Controls.Button)(target));
                return;

            case 29:
                this.m4 = ((System.Windows.Controls.Button)(target));
                return;

            case 30:
                this.y1 = ((System.Windows.Controls.Button)(target));
                return;

            case 31:
                this.y2 = ((System.Windows.Controls.Button)(target));
                return;

            case 32:
                this.max = ((System.Windows.Controls.Button)(target));
                return;

            case 33:
                this.TotalRBTN = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 34:
                this.ActivesRBTN = ((System.Windows.Controls.RadioButton)(target));
                return;

            case 35:
                this.Port_wine = ((System.Windows.Controls.CheckBox)(target));

            #line 1117 "..\..\..\Pages\Report.xaml"
                this.Port_wine.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 36:
                this.Port_investment_bonds = ((System.Windows.Controls.CheckBox)(target));

            #line 1119 "..\..\..\Pages\Report.xaml"
                this.Port_investment_bonds.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 37:
                this.Port_speculation_bonds = ((System.Windows.Controls.CheckBox)(target));

            #line 1129 "..\..\..\Pages\Report.xaml"
                this.Port_speculation_bonds.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 38:
                this.Port_Credit_Linked_Notes = ((System.Windows.Controls.CheckBox)(target));

            #line 1139 "..\..\..\Pages\Report.xaml"
                this.Port_Credit_Linked_Notes.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 39:
                this.Port_SNGC = ((System.Windows.Controls.CheckBox)(target));

            #line 1141 "..\..\..\Pages\Report.xaml"
                this.Port_SNGC.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 40:
                this.Port_SNCC = ((System.Windows.Controls.CheckBox)(target));

            #line 1151 "..\..\..\Pages\Report.xaml"
                this.Port_SNCC.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 41:
                this.Port_SNRS = ((System.Windows.Controls.CheckBox)(target));

            #line 1159 "..\..\..\Pages\Report.xaml"
                this.Port_SNRS.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 42:
                this.Port_Hi_cap_share = ((System.Windows.Controls.CheckBox)(target));

            #line 1167 "..\..\..\Pages\Report.xaml"
                this.Port_Hi_cap_share.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 43:
                this.Port_emerging_markets = ((System.Windows.Controls.CheckBox)(target));

            #line 1169 "..\..\..\Pages\Report.xaml"
                this.Port_emerging_markets.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 44:
                this.Port_mid_cap_share = ((System.Windows.Controls.CheckBox)(target));

            #line 1171 "..\..\..\Pages\Report.xaml"
                this.Port_mid_cap_share.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 45:
                this.Port_lo_cap = ((System.Windows.Controls.CheckBox)(target));

            #line 1176 "..\..\..\Pages\Report.xaml"
                this.Port_lo_cap.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 46:
                this.Port_options = ((System.Windows.Controls.CheckBox)(target));

            #line 1178 "..\..\..\Pages\Report.xaml"
                this.Port_options.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 47:
                this.Port_futures = ((System.Windows.Controls.CheckBox)(target));

            #line 1180 "..\..\..\Pages\Report.xaml"
                this.Port_futures.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 48:
                this.Port_leveraged_ETF = ((System.Windows.Controls.CheckBox)(target));

            #line 1182 "..\..\..\Pages\Report.xaml"
                this.Port_leveraged_ETF.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 49:
                this.Port_mutual_funds = ((System.Windows.Controls.CheckBox)(target));

            #line 1184 "..\..\..\Pages\Report.xaml"
                this.Port_mutual_funds.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 50:
                this.Port_residential_properties = ((System.Windows.Controls.CheckBox)(target));

            #line 1189 "..\..\..\Pages\Report.xaml"
                this.Port_residential_properties.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 51:
                this.Port_commercial_property = ((System.Windows.Controls.CheckBox)(target));

            #line 1191 "..\..\..\Pages\Report.xaml"
                this.Port_commercial_property.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 52:
                this.Port_classics_pictures = ((System.Windows.Controls.CheckBox)(target));

            #line 1193 "..\..\..\Pages\Report.xaml"
                this.Port_classics_pictures.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 53:
                this.Port_modern_pictures = ((System.Windows.Controls.CheckBox)(target));

            #line 1195 "..\..\..\Pages\Report.xaml"
                this.Port_modern_pictures.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 54:
                this.Port_marks = ((System.Windows.Controls.CheckBox)(target));

            #line 1197 "..\..\..\Pages\Report.xaml"
                this.Port_marks.Click += new System.Windows.RoutedEventHandler(this.Resize_dynamic);

            #line default
            #line hidden
                return;

            case 55:
                this.total = ((System.Windows.Controls.CheckBox)(target));
                return;

            case 56:
                this.Onflo_Outflow = ((System.Windows.Controls.Grid)(target));
                return;

            case 57:
                this.FundingTools = ((System.Windows.Controls.DataGrid)(target));
                return;

            case 58:
                this.DGWithdraw = ((System.Windows.Controls.DataGrid)(target));
                return;

            case 59:
                this.Statements = ((System.Windows.Controls.Border)(target));
                return;

            case 60:
                this.Statement = ((System.Windows.Controls.Grid)(target));
                return;

            case 61:
                this.StatementDG = ((System.Windows.Controls.DataGrid)(target));
                return;
            }
            this._contentLoaded = true;
        }