Esempio n. 1
0
        /// <inheritdoc/>
        public override void Assign(GaugePointer src)
        {
            base.Assign(src);

            SimplePointer s = src as SimplePointer;

            Height = s.Height;
            Width  = s.Width;
        }
Esempio n. 2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="SimpleGauge"/> class.
 /// </summary>
 public SimpleGauge() : base()
 {
     InitializeComponent();
     Value   = 75;
     Scale   = new SimpleScale(this);
     Pointer = new SimplePointer(this);
     Height  = 2.0f * Units.Centimeters;
     Width   = 8.0f * Units.Centimeters;
 }
Esempio n. 3
0
        /// <inheritdoc/>
        public override void Serialize(FRWriter writer, string prefix, GaugePointer diff)
        {
            base.Serialize(writer, prefix, diff);

            SimplePointer dc = diff as SimplePointer;

            if (Height != dc.Height)
            {
                writer.WriteFloat(prefix + ".Height", Height);
            }
            if (Width != dc.Width)
            {
                writer.WriteFloat(prefix + ".Width", Width);
            }
        }