Esempio n. 1
0
        /// <summary>
        /// 创建一个列表项
        /// </summary>
        /// <param name="style">行的类型</param>
        /// <param name="inverveStyle">是否交换前景色和背景色配置</param>
        /// <param name="text">文本内容</param>
        /// <returns>创建的列表项</returns>
        public static ListViewItem CreateItemStatic(ColorSchema style, bool inverveStyle, string text)
        {
            ListViewItem lit = new ListViewItem()
            {
                Text = text,
                UseItemStyleForSubItems = true
            };

            ListViewResource.SwitchListViewItemStyle(lit, style, inverveStyle);

            return(lit);
        }
Esempio n. 2
0
        /// <summary>
        /// 创建一个列表项
        /// </summary>
        /// <param name="style">行的类型</param>
        /// <param name="reserveStyle">是否交换前景色和背景色配置</param>
        /// <param name="text">文本内容</param>
        /// <returns>创建的列表项</returns>
        public static ListViewItem CreateItemStatic(RowStyleType style, bool reserveStyle, string text)
        {
            ListViewItem lit = new ListViewItem()
            {
                Text = text,
                UseItemStyleForSubItems = true
            };

            ListViewResource.SwitchListViewItemStyle(lit, style, reserveStyle);

            return(lit);
        }
Esempio n. 3
0
 public void ApplyColorSchema(RowStyleType type)
 {
     ApplyColorSchema(ListViewResource.Style(type));
 }