コード例 #1
0
        private static LineSettings CreateLine(LineSettings0 settings)
        {
            LineSettings result = new LineSettings();

            result.Volume   = settings.Volume;
            result.BidColor = ColorSerializer.ColorFromString(settings.BidColor);
            result.AskColor = ColorSerializer.ColorFromString(settings.AskColor);
            return(result);
        }
コード例 #2
0
        private static LineSettings0 CreateLine(LineSettings settings)
        {
            LineSettings0 result = new LineSettings0();

            result.BidColor = ColorSerializer.StringFromColor(settings.BidColor);
            result.AskColor = ColorSerializer.StringFromColor(settings.AskColor);
            result.Volume   = settings.Volume;

            return(result);
        }
コード例 #3
0
        private static ChartSettings CreateChart(ChartSettings0 settings)
        {
            ChartSettings result = new ChartSettings();

            result.Mode            = (RenderingMode)settings.Mode;
            result.Type            = (LineType)settings.Type;
            result.Grid            = settings.Grid;
            result.BackgroundColor = ColorSerializer.ColorFromString(settings.BackgroundColor);
            result.ForegroundColor = ColorSerializer.ColorFromString(settings.ForegroundColor);
            result.Duration        = settings.Duration;
            result.Height          = settings.Height;
            result.UpdateInterval  = settings.UpdateInterval;
            CreateLines(settings.Lines, result.Lines);
            return(result);
        }
コード例 #4
0
        private static ChartSettings0 CreateChart(string symbol, ChartSettings settings)
        {
            ChartSettings0 result = new ChartSettings0();

            result.Symbol          = symbol;
            result.Mode            = (Mode0)settings.Mode;
            result.Type            = (LineType0)settings.Type;
            result.Grid            = settings.Grid;
            result.BackgroundColor = ColorSerializer.StringFromColor(settings.BackgroundColor);
            result.ForegroundColor = ColorSerializer.StringFromColor(settings.ForegroundColor);
            result.Duration        = settings.Duration;
            result.Height          = settings.Height;
            result.UpdateInterval  = settings.UpdateInterval;

            result.Lines = CreateLines(settings.Lines);

            return(result);
        }