using System.Collections.Generic; using System.Windows; using MuchInfo.Chart.Data.EnumTypes; namespace MuchInfo.Chart.WPF.Primitives.Interfaces { #region Delegates public delegate void ScalePropertiesChangedEventHandler(); #endregion Delegates public interface IValueScaler { #region Events event ScalePropertiesChangedEventHandler ScalePropertiesChanged; #endregion Events #region Properties bool Inverse { get; set; } #endregion Properties #region Methods void CalculateScale(List plots, IDateScaler scaler, bool isTimeSpaning); float PercentFromValue(float aVal); float PercentFromValueDisplay(float aVal); float ScaledY(float aVal, Rect aRect); float Spread(); float ValueFromPercent(float aPercent); float ValueFromPercentDisplay(float aPercent); float ValueFromY(float aY, Rect aRect); float YFromPercent(float aPercent, Rect aRect); float GetMaxValue(); float GetMinValue(); bool ShowScaleAsPercent { get; set; } float GetPercentBaseline(); /// /// 设置是否显示分时图 /// bool IsTimeSpaning { get; set; } /// /// 显示分时图中昨收价 /// float TimeSpaningLast { get; set; } #endregion Methods } }