public FormBase( ) { InitializeComponent( ); defaultLookAndFeel.LookAndFeel.SkinName = ConfigHelper.getFeedConfig( ); Skin GridSkin = GridSkins.GetSkin(defaultLookAndFeel.LookAndFeel); }
public void BindingTreeView(DataTable dt) { try { treeList.DataSource = dt; treeList.KeyFieldName = "ID"; treeList.ParentFieldName = "PARENTID"; treeList.Columns["ID_NAME"].Visible = false; Skin skin = GridSkins.GetSkin(treeList.LookAndFeel); skin.Properties[GridSkins.OptShowTreeLine] = true; chkAll.Checked = true; foreach (TreeListNode node in treeList.Nodes) { var dataRow = treeList.GetDataRecordByNode(node); node.Tag = dataRow; node.Checked = true; node.Expanded = true; foreach (TreeListNode node1 in node.RootNode.Nodes) { if (node.Checked) { node1.Checked = true; } } } } catch (Exception ex) { } }
public static Color GetSkinBackColor(string skinName) { var skin = GridSkins.GetSkin(DevExpress.LookAndFeel.UserLookAndFeel.Default); var skinElement = skin[skinName]; return(skinElement.Color.BackColor); }
private void gridControl1_PaintEx(object sender, DevExpress.XtraGrid.PaintExEventArgs e) { SkinElement elem = GridSkins.GetSkin(this.gridControl1.LookAndFeel.ActiveLookAndFeel)[GridSkins.SkinGridLine]; e.Cache.DrawLine(e.Cache.GetPen(elem.Color.ForeColor), new Point(e.ClipRectangle.X, e.ClipRectangle.Top), new Point(e.ClipRectangle.Right, e.ClipRectangle.Top)); }
public f_phanquyenchucnang() { InitializeComponent(); gd.DataSource = (from a in dbData.phongbans where a.phanquyen == true select a); treeList1.ExpandAll(); var skin = GridSkins.GetSkin(treeList1.LookAndFeel); skin.Properties[GridSkins.OptShowTreeLine] = true; }
public static Color GetHeaderForeColor(UserLookAndFeel lf) { Color ret = SystemColors.ControlText; if (lf.ActiveStyle != ActiveLookAndFeelStyle.Skin) { return(ret); } return(GridSkins.GetSkin(lf)[GridSkins.SkinHeader].Color.GetForeColor()); }
public ChartControl2( ) { InitializeComponent( ); defaultLookAndFeel.LookAndFeel.SkinName = "Visual Studio 2013 Dark"; Skin GridSkin = GridSkins.GetSkin(defaultLookAndFeel.LookAndFeel); this.WindowState = System.Windows.Forms.FormWindowState.Maximized; getTableView( ); }
public static void ChangeSkin(string skinName) { UserLookAndFeel.Default.SkinName = skinName; var skin = GridSkins.GetSkin(UserLookAndFeel.Default); EditRowColor = skin[GridSkins.SkinGridGroupPanel].Color.BackColor; skin = BarSkins.GetSkin(UserLookAndFeel.Default); BackTitleColor = skin[BarSkins.SkinMainMenu].Color.BackColor; TitleColor = skin[BarSkins.SkinMainMenu].Color.ForeColor; }
public FrmPhanQuyen() { InitializeComponent(); repChucDanh.Items.AddEnum(typeof(ChucDanh), true); treeList1.ExpandAll(); Skin skin = GridSkins.GetSkin(treeList1.LookAndFeel); skin.Properties[GridSkins.OptShowTreeLine] = true; UseEnableControl = false; }
Color GetBackColor() { if (ElementsLookAndFeel.ActiveStyle == ActiveLookAndFeelStyle.Skin) { SkinElement element = GridSkins.GetSkin(ElementsLookAndFeel)[GridSkins.SkinGridGroupPanel]; if (element.Color.BackColor2 != Color.Empty) { return(element.Color.BackColor2); } } return(LookAndFeelHelper.GetSystemColor(ElementsLookAndFeel, SystemColors.Control)); }
public ChartControl2( ) { InitializeComponent( ); //defaultLookAndFeel . LookAndFeel . SkinName = "Visual Studio 2013 Dark"; Skin GridSkin = GridSkins.GetSkin(defaultLookAndFeel.LookAndFeel); MulaolaoBll.UserInfoMation.tableName = this.Name; this.WindowState = System.Windows.Forms.FormWindowState.Maximized; getTableView( ); }
public FormBase( ) { InitializeComponent( ); strFeel = config.AppSettings.Settings ["Feed"].Value; if (string.IsNullOrEmpty(strFeel)) { strFeel = "Office 2013 Light Gray"; } defaultLookAndFeel.LookAndFeel.SkinName = strFeel; Skin GridSkin = GridSkins.GetSkin(defaultLookAndFeel.LookAndFeel); LineProductMesBll.UserInfoMation.FeedColor = GridSkin [GridSkins.SkinGridEvenRow].Color.BackColor; }
private static Image GetExpandButtonImage(RowObjectCustomDrawEventArgs e, GridView view, DevExpress.LookAndFeel.UserLookAndFeel lookAndFeel) { var currentSkin = GridSkins.GetSkin(lookAndFeel); var plusMinusButton = currentSkin[GridSkins.SkinPlusMinus]; ImageCollection images = plusMinusButton.Image?.GetImages() ?? plusMinusButton.Glyph?.GetImages(); if (images == null) { return(null); } var rowExpanded = view.GetRowExpanded(e.RowHandle); var imgIndex = rowExpanded ? 1 : 0; var img = images.Images[imgIndex]; return(img); }
public void BindingTree(DataTable dt) { treeList1.DataSource = dt; treeList1.KeyFieldName = "ID"; treeList1.ParentFieldName = "PARENTID"; Skin skin = GridSkins.GetSkin(treeList1.LookAndFeel); skin.Properties[GridSkins.OptShowTreeLine] = true; foreach (TreeListNode node in treeList1.Nodes) { var dataRow = treeList1.GetDataRecordByNode(node); node.Tag = dataRow; if (node.Id <= 4) { node.Expanded = true; } } }
public static void SetReadOnlyStyle(this GridControl control) { var gridSkin = GridSkins.GetSkin(control.LookAndFeel.ActiveLookAndFeel); var commonSkin = CommonSkins.GetSkin(control.LookAndFeel.ActiveLookAndFeel); if (commonSkin == null) { return; } var bgColor = commonSkin.Colors.GetColor(CommonColors.ReadOnly); var foreColor = Color.DimGray; foreach (var view in control.Views.OfType <ColumnView>()) { foreach (GridColumn column in view.Columns) { if (!column.OptionsColumn.AllowEdit || column.OptionsColumn.ReadOnly) { column.OptionsColumn.AllowEdit = false; column.OptionsColumn.ReadOnly = true; column.AppearanceCell.BackColor = bgColor; column.AppearanceCell.Options.UseBackColor = true; column.AppearanceCell.ForeColor = foreColor; column.AppearanceCell.Options.UseForeColor = true; } } var gridView = view as GridView; if (gridView != null && gridSkin != null) { gridView.CustomDrawCell += (sender, args) => DrawDefault(args, gridSkin); } } }
internal static Color GetRowForeColor(GridControl gridControl) { return(GridSkins.GetSkin(gridControl.LookAndFeel)[GridSkins.SkinGridRow].GetForeColor(Utils.Drawing.ObjectState.Normal)); }
internal static Color GetRowBackColor(GridControl gridControl) { return(GridSkins.GetSkin(gridControl.LookAndFeel)[GridSkins.SkinGridRow].Color.BackColor); }
public static Skin GetCurrentGridSkin() { return(GridSkins.GetSkin(GetCurrentUserLookAndFeel)); }