38 m_dataGrid->SetColLabelValue( 0,
_(
"Rule type" ) );
39 m_dataGrid->SetColLabelValue( 1,
_(
"Rule name" ) );
44 for(
size_t i = 0; i <
m_rows.size(); ++i )
46 m_dataGrid->SetCellValue( i, 0, m_rows[i].m_ruleType );
47 m_dataGrid->SetCellValue( i, 1, m_rows[i].m_ruleName );
48 m_dataGrid->SetCellValue( i, 2, m_rows[i].m_comment );
74 wxSize clientSize = GetClientSize();
75 int availableWidth = clientSize.GetWidth() - wxSystemSettings::GetMetric( wxSYS_VSCROLL_X );
76 int availableHeight = clientSize.GetHeight() - wxSystemSettings::GetMetric( wxSYS_HSCROLL_Y );
78 m_dataGrid->SetSize( wxSize( availableWidth, availableHeight ) );
80 double col0_width_ratio =
m_dataGrid->GetColSize( 0 ) / total_column_width;
81 double col1_width_ratio =
m_dataGrid->GetColSize( 1 ) / total_column_width;
82 int col0_size =
static_cast<int>( availableWidth * col0_width_ratio );
83 int col1_size =
static_cast<int>( availableWidth * col1_width_ratio );
84 int col2_size = availableWidth - col0_size - col1_size;