public CRow Clone() { CRow nrw = new CRow(nm, h, column); foreach (CColumn c in columns) { CColumn o = c.Clone(); nrw.AddColumn(o); } nrw.SetMargin(this.margin); nrw.SetFont(this.ff, this.fs, this.fz, this.fw); return(nrw); }
private void CreateDefaultHeader() { String nm = ""; Thickness defMargin = new Thickness(3, 1, 3, 1); CColumn c0_0 = new CColumn(new Thickness(0, 0, 0, 0), new GridLength(50, GridUnitType.Star)); c0_0.SetHorizontalAlignment(HorizontalAlignment.Left); CColumn c0_1 = new CColumn(new Thickness(0, 0, 0, 0), new GridLength(50, GridUnitType.Star)); c0_1.SetHorizontalAlignment(HorizontalAlignment.Right); nm = "GLB_HEADER_LEVEL0"; CRow h0 = new CRow(nm, 20, 2, defMargin); h0.SetFont(null, FontStyles.Normal, 10, FontWeights.Normal); h0.AddColumn(c0_0); h0.AddColumn(c0_1); rowdef[nm] = h0; CColumn c1_0 = new CColumn(new Thickness(0, 0, 0, 0), new GridLength(100, GridUnitType.Star)); nm = "GLB_HEADER_LEVEL1"; CRow h1 = new CRow(nm, 30, 1, defMargin); h1.SetFont(null, FontStyles.Normal, 0, FontWeights.Bold); h1.AddColumn(c1_0); rowdef[nm] = h1; CColumn c1_2 = new CColumn(new Thickness(0, 0, 0, 0), new GridLength(100, GridUnitType.Star)); nm = "GLB_HEADER_PARAM"; CRow h2 = new CRow(nm, 30, 1, defMargin); h2.SetFont(null, FontStyles.Normal, 0, FontWeights.Bold); h2.AddColumn(c1_2); rowdef[nm] = h2; }