private void SetColumnsWidth(MatrixGroupView i_View) { if (i_View == null) { return; } if (i_View.ColumnsWidth == null || i_View.ColumnsWidth.Count <= 0) { return; } if (i_View.PrintingTable != null) { int ColumnsCount = i_View.PrintingTable.GetColumns(); i_View.ColumnsWidth.Clear(); Int32Collection ColumnsWidthCopy = new Int32Collection(); for (int i = 0; i < ColumnsCount; i++) { i_View.ColumnsWidth.Add(i_View.PrintingTable.GetColumnWidth(i)); } } int nCol = 0; if (i_View.ShowRowIndicators) { nCol++; } GroupInfo m_GroupInfo = i_View.RootGroupInfo; ApplyMatrixColumnsWidth(m_GroupInfo, ref nCol, i_View.ColumnsWidth, i_View.MatrixInfo); }
public override void UpdateView(Webb.Reports.ExControls.Views.ExControlView i_View) { this.UpdateMatrixStyle(); int nCol = 0; if (i_View is CompactGroupView) { CompactGroupView m_CompactGroupView = i_View as CompactGroupView; if (!m_CompactGroupView.Matrix) { this.palMatrix.Enabled = false; return; } m_CompactGroupView.MatrixInfo = matrixInfo.Copy(); if (m_CompactGroupView.ShowRowIndicators) { nCol++; } //UpdateMatrixColumnsWidth(m_CompactGroupView.RootGroupInfo, ref nCol, m_CompactGroupView.ColumnsWidth, m_CompactGroupView.MatrixInfo); } else { MatrixGroupView m_MatrixGroupView = i_View as MatrixGroupView; m_MatrixGroupView.MatrixInfo = matrixInfo.Copy(); if (m_MatrixGroupView.ShowRowIndicators) { nCol++; } //UpdateMatrixColumnsWidth(m_MatrixGroupView.RootGroupInfo, ref nCol, m_MatrixGroupView.ColumnsWidth, m_MatrixGroupView.MatrixInfo); } }
public override void SetView(Webb.Reports.ExControls.Views.ExControlView i_View) { if (i_View is CompactGroupView) { CompactGroupView m_CompactGroupView = i_View as CompactGroupView; if (!m_CompactGroupView.Matrix) { this.palMatrix.Enabled = false; return; } if (m_CompactGroupView.MatrixDisplay == ComputedStyle.Grid) { this.Disgroup.Visible = false; } else { this.Disgroup.Visible = true; } this.palMatrix.Enabled = true; if (m_CompactGroupView.MatrixInfo == null) { if (m_CompactGroupView.RootGroupInfo == null || m_CompactGroupView.RootGroupInfo.SubGroupInfos == null || m_CompactGroupView.RootGroupInfo.SubGroupInfos.Count == 0) { matrixInfo = new MatrixInfo(m_CompactGroupView.RootGroupInfo, null, null, null); } else { matrixInfo = new MatrixInfo(m_CompactGroupView.RootGroupInfo, m_CompactGroupView.RootGroupInfo.SubGroupInfos[0], null, null); } } else { matrixInfo = m_CompactGroupView.MatrixInfo.Copy(); } this.SetColumnsWidth(m_CompactGroupView); //Add this code at 2011-6-8 15:40:30@simon } else { MatrixGroupView m_MatrixGroupView = i_View as MatrixGroupView; if (m_MatrixGroupView.MatrixDisplay == ComputedStyle.Grid) { this.Disgroup.Visible = false; } else { this.Disgroup.Visible = true; } this.palMatrix.Enabled = true; if (m_MatrixGroupView.MatrixInfo == null) { if (m_MatrixGroupView.RootGroupInfo == null || m_MatrixGroupView.RootGroupInfo.SubGroupInfos == null || m_MatrixGroupView.RootGroupInfo.SubGroupInfos.Count == 0) { matrixInfo = new MatrixInfo(m_MatrixGroupView.RootGroupInfo, null, null, null); } else { matrixInfo = new MatrixInfo(m_MatrixGroupView.RootGroupInfo, m_MatrixGroupView.RootGroupInfo.SubGroupInfos[0], null, null); } } else { matrixInfo = m_MatrixGroupView.MatrixInfo.Copy(); } this.SetColumnsWidth(m_MatrixGroupView); //Add this code at 2011-6-8 15:40:30@simon } this.SetMatrixStyle(); }