Exemplo n.º 1
0
        public TextScale()
        {
            _dataBounds = new TextBoundaries();
            _dataBounds.BoundaryChanged += EhBoundariesChanged;

            _rescaling = new NumericAxisRescaleConditions();
        }
        public NumericAxisRescaleController(NumericAxisRescaleConditions doc, NumericalScale ax)
        {
            _doc  = doc;
            _axis = ax;

            SetElements(true);
        }
Exemplo n.º 3
0
        public void ProcessDataBounds(double xorg, double xend, NumericAxisRescaleConditions rescaling)
        {
            bool isAutoOrg, isAutoEnd;

            rescaling.Process(ref xorg, out isAutoOrg, ref xend, out isAutoEnd);
            ProcessDataBounds(xorg, !isAutoOrg, xend, !isAutoEnd);
        }
Exemplo n.º 4
0
        void CopyFrom(TextScale from)
        {
            _dataBounds = (TextBoundaries)from._dataBounds.Clone();
            _dataBounds.BoundaryChanged += EhBoundariesChanged;

            _rescaling = from._rescaling == null ? null : (NumericAxisRescaleConditions)from._rescaling.Clone();

            _cachedAxisOrg       = from._cachedAxisOrg;
            _cachedAxisEnd       = from._cachedAxisEnd;
            _cachedAxisSpan      = from._cachedAxisSpan;
            _cachedOneByAxisSpan = from._cachedOneByAxisSpan;
        }
Exemplo n.º 5
0
        /// <summary>
        /// Copy constructor.
        /// </summary>
        /// <param name="from">A other linear axis from which to copy from.</param>
        public LinearScale(LinearScale from)
        {
            this.IsLinked = from.IsLinked;

            this._cachedAxisEnd          = from._cachedAxisEnd;
            this._axisEndByMajor         = from._axisEndByMajor;
            this._cachedAxisOrg          = from._cachedAxisOrg;
            this._axisOrgByMajor         = from._axisOrgByMajor;
            this._cachedAxisSpan         = from._cachedAxisSpan;
            this._baseEnd                = from._baseEnd;
            this._baseOrg                = from._baseOrg;
            this._dataBounds             = null == from._dataBounds ? new FiniteNumericalBoundaries() : (NumericalBoundaries)from._dataBounds.Clone();
            _dataBounds.BoundaryChanged += new BoundaryChangedHandler(this.OnBoundariesChanged);
            this._majorSpan              = from._majorSpan;
            this._minorTicks             = from._minorTicks;
            this._cachedOneByAxisSpan    = from._cachedOneByAxisSpan;

            this._rescaling = null == from.Rescaling ? new NumericAxisRescaleConditions() : (NumericAxisRescaleConditions)from.Rescaling.Clone();
        }