Ejemplo n.º 1
0
        internal void RemoveMeasure(BulletGraphMeasureBase measure)
        {
            if (!this.IsTemplateApplied)
            {
                return;
            }

            this.scalePart.Indicators.Remove(measure.Visual);
            this.scalePart.InvalidateMeasure();
        }
Ejemplo n.º 2
0
        internal void InsertMeasure(int index, BulletGraphMeasureBase measure)
        {
            if (!this.IsTemplateApplied)
            {
                return;
            }

            this.scalePart.Indicators.Insert(index, measure.Visual);
            this.SyncComparativeMeasureTemplate(measure as BulletGraphComparativeMeasure);
            this.scalePart.InvalidateMeasure();
        }
Ejemplo n.º 3
0
        internal void SetMeasure(BulletGraphMeasureBase newMeasure, BulletGraphMeasureBase oldMeasure)
        {
            if (!this.IsTemplateApplied)
            {
                return;
            }

            int oldIndex = this.scalePart.Indicators.IndexOf(oldMeasure.Visual);

            this.scalePart.Indicators[oldIndex] = newMeasure.Visual;

            this.SyncComparativeMeasureTemplate(newMeasure as BulletGraphComparativeMeasure);
            this.scalePart.InvalidateMeasure();
        }
Ejemplo n.º 4
0
        private static void OnValuePropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            BulletGraphMeasureBase measure = d as BulletGraphMeasureBase;

            measure.Visual.Value = (double)e.NewValue;
        }