using MultiLayout.UiModule;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace FLY.Thick.FilmCasting.UI.UiModule
{
    /// <summary>
    /// 超大混合扫描图的参数
    /// </summary>
    public class GiantMixScanGraph2ItemParam : UIModuleParam
    {
        /// <summary>
        /// Y轴比例
        /// </summary>
        public double YRangePercent { get; set; } = 3;

        private int mix = 100;

        /// <summary>
        /// 均值混合数
        /// </summary>
        public int Mix {
            get => mix;
            set {
                if (value < 0) value = 1;
                else if (value > 200) value = 200;
                if (value != mix)
                {
                    mix = value;
                }
            }
        }

        private int cellMix = 3;
        /// <summary>
        /// 单元混合数
        /// </summary>
        public int CellMix 
        {
            get => cellMix;
            set {
                if (value < 0) value = 1;
                else if (value > 10) value = 10;
                if (value != cellMix) {
                    cellMix = value;
                }
            }
        }

        /// <summary>
        /// 从某Id 开始， 用于按清空后，从按清空的Id 开始计算
        /// 统计Id
        /// </summary>
        public long FromId { get; set; }

        /// <summary>
        /// Y轴%显示
        /// </summary>
        public bool IsPercent { get; set; } = true;

        /// <summary>
        /// Y轴自动目标值
        /// </summary>
        public bool IsAutoTarget { get; set; } = true;

        /// <summary>
        /// 曲线模式
        /// </summary>
        public bool IsLineMode { get; set; }

        /// <summary>
        /// 数据范围外数据隐藏
        /// </summary>
        public bool IsSideCutHidden { get; set; }
    }
}
