using ComPDFKit.PDFDocument;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace PDF_Office.Model.EditTools.Background
{
    public class BackgroundCreateModel
    {
    }

    public enum EnumBackgroundType
    {
        StatusColor,
        StatusFile
    }

    public class BackgroundInfo
    {
        /// <summary>
        /// 背景类型
        /// </summary>
        public C_Background_Type BackgroundType = C_Background_Type.BG_TYPE_COLOR; 

        /// <summary>
        /// 纯色背景颜色
        /// </summary>
        public byte[] Color;

        /// <summary>
        /// 图片背景数据
        /// </summary>
        public byte[] ImageArray;

        /// <summary>
        /// 背景旋转角度
        /// </summary>
        public float Rotation;
        
        /// <summary>
        /// 背景透明度
        /// </summary>
        public byte Opacity;
        
        /// <summary>
        /// 是否相对比例
        /// </summary>
        public bool IsRelativeRatio;
        
        /// <summary>
        ///相对比例大小 
        /// </summary>
        public int RelativeRatio;

        /// <summary>
        /// 
        /// </summary>
        public float Scale;

        /// <summary>
        /// 背景相对垂直距离;
        /// </summary>
        public float VertOffset = 0;

        /// <summary>
        /// 背景相对水平距离;
        /// </summary>
        public float HorizOffset = 0;

        /// <summary>
        /// 图片背景：宽度
        /// </summary>
        public int ImageWidth;
            
        /// <summary>
        /// 图片背景：长度
        /// </summary>
        public int ImageHeight;

        /// <summary>
        ///垂直位置
        /// </summary>
        public C_Background_Vertalign Vertalign;

        /// <summary>
        /// 水平位置
        /// </summary>
        public C_Background_Horizalign Horizalign;


        /// <summary>
        /// 页码范围
        /// </summary>
        public string PageRange = "0";

        /// <summary>
        /// 页面范围索引;
        /// 0:全部页面
        /// 1:奇数页
        /// 2;偶数页
        /// 3:自定义页
        /// </summary>
        public int PageRangeIndex = 0;
    }
}
