public void AppendColumnSetting(ColumnSetting columnSetting) { if (string.IsNullOrEmpty(columnSetting.columnBaseInfo.dataName)) { columnSetting.columnBaseInfo.dataName = "_COL_" + columnSettingList.Count; } columnSettingList.Add(columnSetting); }
ScLayer CreateItemControlField(ScMgr scmgr, ColumnSetting columnSetting) { ScLabel label = new ScLabel(scmgr); label.Dock = ScDockStyle.Fill; label.ForeFont = new D2DFont("微软雅黑", 12, SharpDX.DirectWrite.FontWeight.Regular); label.ForeColor = Color.FromArgb(255, 58, 166, 254); return(label); }
public void CreateDefaultContentInfoSeting() { ClearColumnSetting(); ColumnSetting columnSetting = new ColumnSetting("col", "列", true, false, 200); columnSetting.CreateHeaderControl += CreateHeaderControlField; columnSetting.CreateItemControl += CreateItemControlField; columnSetting.DisplayItemValue += DisplayItemValue; AppendColumnSetting(columnSetting); AppendColumnSettingEnd(); }
ScLayer CreateHeaderControlField(ScMgr scmgr, ColumnSetting columnSetting) { ScLabel label = new ScLabel(scmgr); label.Dock = ScDockStyle.Fill; label.ForeFont = new D2DFont("微软雅黑", 12, SharpDX.DirectWrite.FontWeight.Bold); if (!columnSetting.columnBaseInfo.isHideName) { label.Text = columnSetting.columnBaseInfo.displayName; } return(label); }