Example #1
0
 /// <summary>
 /// 当全局样式发生变化时调用
 /// </summary>
 public void OnSetRowColor(object p_RowObject, _SchemeColor p__SchemeColor, DevExpress.Utils.AppearanceObject appearance)
 {
     if (this.SetRowColorChange != null)
     {
         this.SetRowColorChange(p_RowObject, p__SchemeColor, appearance);
     }
 }
Example #2
0
        /// <summary>
        /// 创建新样式
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void simpleButton1_Click_1(object sender, EventArgs e)
        {
            //string path = APP.Application.Global.AppFolder.FullName;
            //string str = string.Format("{0}config\\options.cfg", path);
            _SchemeColor sc = new _SchemeColor();

            APP.DataObjects.GColor = new GlobalStyle();
            APP.DataObjects.GColor.Init(this.AppForm.SkinString);
            APP.DataObjects.GColor.Init(new string[] { "全局皮肤" });
            //保存一个新的配置
            //APP.DataObjects.GColor.ColumnLayout = new _ColumnLayout();
            //APP.DataObjects.GColor.ColumnLayout.Get()
            APP.DataObjects.Save(@"d:\options_New.cfg");
        }
Example #3
0
        private void gridView1_SetRowColorChange(object p_RowObject, _SchemeColor p_SchemeColor, DevExpress.Utils.AppearanceObject appearance)
        {
            _ObjectQuantityUnitInfo info = (p_RowObject as _ObjectQuantityUnitInfo);

            if (info.YSBH == info.BH && info.YSDW == info.DW && info.YSMC == info.MC && info.SCDJ != info.DEDJ)
            {
                //获取特殊样式绑定颜色
                _SpecialStyleInfo style = p_SchemeColor.SpecialStyle.Get("市场单价修改");
                if (style != null)
                {
                    appearance.Font = new Font(appearance.Font.FontFamily, appearance.Font.Size, style.Font);
                    //字体颜色
                    appearance.ForeColor = style.ForeColor.IsEmpty ? appearance.ForeColor : style.ForeColor;
                    //背景颜色
                    appearance.BackColor = style.BColor.IsEmpty ? appearance.BackColor : style.BColor;

                    appearance.BackColor2 = style.BColor2.IsEmpty ? appearance.BackColor2 : style.BColor2;
                }
            }
        }
Example #4
0
        private void gridView1_SetRowColorChange(object p_RowObject, _SchemeColor p_SchemeColor, DevExpress.Utils.AppearanceObject appearance)
        {
            DataRowView info = (p_RowObject as DataRowView);

            if (info["YSBH"] == info["BH"] && info["YSDW"] == info["DW"] && info["YSMC"] == info["MC"] && !info["SCDJ"].Equals(info["DEDJ"]))
            {
                //获取特殊样式绑定颜色
                _SpecialStyleInfo style = p_SchemeColor.SpecialStyle.Get("市场单价修改");
                if (style != null)
                {
                    appearance.Font = new Font(appearance.Font.FontFamily, appearance.Font.Size, style.Font);
                    //字体颜色
                    appearance.ForeColor = style.ForeColor.IsEmpty ? appearance.ForeColor : style.ForeColor;
                    //背景颜色
                    appearance.BackColor = style.BColor.IsEmpty ? appearance.BackColor : style.BColor;

                    appearance.BackColor2 = style.BColor2.IsEmpty ? appearance.BackColor2 : style.BColor2;
                }
            }
        }
Example #5
0
 /// <summary>
 /// 重新获取选择方案使用框架修改后调用
 /// </summary>
 private void RestUseColor()
 {
     this.TempUseColor = m_UseColor.Current().Copy();
 }