Beispiel #1
0
        private QuantityThemeItem(QuantityThemeItem another)
        {
            Interval = new Interval(another.Interval);
            style = (IStyle) another.Style.Clone();

            // label should be set after interval because when the interval
            // property is set, it also sets a default value for the label property
            label = another.label.Clone() as string;
        }
Beispiel #2
0
        private QuantityThemeItem(QuantityThemeItem another)
        {
            Interval = new Interval(another.Interval);
            style    = (IStyle)another.Style.Clone();

            // label should be set after interval because when the interval
            // property is set, it also sets a default value for the label property
            label = another.label.Clone() as string;
        }
Beispiel #3
0
        public void AddStyle(IStyle style, Interval interval)
        {
            var quantityThemeItem = new QuantityThemeItem(interval, style);

            ThemeItems.Add(quantityThemeItem);
        }
Beispiel #4
0
        private static QuantityTheme GetQuantityTheme(theme theme)
        {
            var themeQuantity = (themeQuantity) theme.Item;

            var quanTheme = new QuantityTheme(themeQuantity.columnName, GetDefaultStyle(theme))
                                {
                                    NoDataValues = ConvertNoDataValues(themeQuantity.noDataValues, themeQuantity.noDataValueType)
                                };
                        
            foreach (themeItem quanThemeItem in themeQuantity.quantityThemeItems)
            {
                var themeStyle = GetStyle(quanThemeItem);
                var interval = new Interval(quanThemeItem.intervalMinValue,
                                            quanThemeItem.intervalMaxValue);

                var themeItem = new QuantityThemeItem(interval, themeStyle) {Label = quanThemeItem.label};
                quanTheme.ThemeItems.Add(themeItem);
            }
            
            return quanTheme;
        }