本文整理汇总了C#中System.Windows.Forms.ColumnWidthChangedEventArgs类的典型用法代码示例。如果您正苦于以下问题:C# ColumnWidthChangedEventArgs类的具体用法?C# ColumnWidthChangedEventArgs怎么用?C# ColumnWidthChangedEventArgs使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
ColumnWidthChangedEventArgs类属于System.Windows.Forms命名空间,在下文中一共展示了ColumnWidthChangedEventArgs类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BitList_ColumnWidthChanged
private void BitList_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
this.BitList.ColumnWidthChanged -= BitList_ColumnWidthChanged;
switch (e.ColumnIndex)
{
case 0: this.BitList.Columns[0].Width = 30; break;
case 1: this.BitList.Columns[1].Width = 46; break;
case 2: this.BitList.Columns[2].Width = 93; break;
}
this.BitList.ColumnWidthChanged += BitList_ColumnWidthChanged;
}
示例2: ColumnWidthChanged
/// <summary>
/// Save columns' widths every time they change. This will happen when the
/// form loads for the first time and then every time a user drags and resizes a column
/// </summary>
private void ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
// Store new width only when there are items on the list. This check also prevents
// the code from storing initial loaded columns when the form is created
if (listRepos.Items.Count > 0)
{
int[] columns = (int[])Properties.Settings.Default.ReposColumnWidths;
if (columns == null)
columns = new int[4];
columns[e.ColumnIndex] = listRepos.Columns[e.ColumnIndex].Width;
Properties.Settings.Default.ReposColumnWidths = columns;
}
}
示例3: HandleColumnWidthChanged
/// <summary>
/// When the column widths change, resize the space filling columns
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
protected virtual void HandleColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
if (!this.GetColumn(e.ColumnIndex).FillsFreeSpace)
this.ResizeFreeSpaceFillingColumns();
}
示例4: HistoryListView_ColumnWidthChanged
void HistoryListView_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
SaveColumnWidths();
}
示例5: SubtitleListViewColumnWidthChanged
private void SubtitleListViewColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
if (_settings != null && _saveColumnWidthChanges)
{
switch (e.ColumnIndex)
{
case ColumnIndexNumber:
Configuration.Settings.General.ListViewNumberWidth = Columns[ColumnIndexNumber].Width;
break;
case ColumnIndexStart:
Configuration.Settings.General.ListViewStartWidth = Columns[ColumnIndexStart].Width;
break;
case ColumnIndexEnd:
Configuration.Settings.General.ListViewEndWidth = Columns[ColumnIndexEnd].Width;
break;
case ColumnIndexDuration:
Configuration.Settings.General.ListViewDurationWidth = Columns[ColumnIndexDuration].Width;
break;
case ColumnIndexText:
Configuration.Settings.General.ListViewTextWidth = Columns[ColumnIndexText].Width;
break;
}
}
}
示例6: OnColumnWidthChanged
private void OnColumnWidthChanged (object sender, ColumnWidthChangedEventArgs args)
{
if (args.ColumnIndex
== itemProvider.HeaderProvider.ListView.Columns.IndexOf (itemProvider.ColumnHeader))
RaiseAutomationPropertyChangedEvent ();
}
示例7: RaiseColumnWidthChanged
void RaiseColumnWidthChanged (int resize_column)
{
ColumnWidthChangedEventArgs n = new ColumnWidthChangedEventArgs (resize_column);
OnColumnWidthChanged (n);
}
示例8: OnPwListColumnWidthChanged
private void OnPwListColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
UpdateColumnsEx(true);
}
示例9: OnColumnWidthChanged
/// <include file='doc\ListView.uex' path='docs/doc[@for="ListView.OnColumnWidthChanged"]/*' />
/// <devdoc>
/// Fires the column width changing event.
/// </devdoc>
protected virtual void OnColumnWidthChanged(ColumnWidthChangedEventArgs e) {
ColumnWidthChangedEventHandler handler = (ColumnWidthChangedEventHandler)Events[EVENT_COLUMNWIDTHCHANGED];
if (handler != null) {
handler(this, e);
}
}
示例10: lvSkills_ColumnWidthChanged
/// <summary>
/// When the user manually resizes a column, we make sure to update the column preferences.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void lvSkills_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
if (m_isUpdatingColumns)
return;
if (m_columns.Count <= e.ColumnIndex)
return;
m_columns[e.ColumnIndex].Width = lvSkills.Columns[e.ColumnIndex].Width;
Settings.UI.PlanWindow.Columns.Clear();
Settings.UI.PlanWindow.Columns.AddRange(ExportColumnSettings());
}
示例11: lvResearchPoints_ColumnWidthChanged
/// <summary>
/// When the user manually resizes a column, we make sure to update the column preferences.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
void lvResearchPoints_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
if (m_isUpdatingColumns || m_columns.Count <= e.ColumnIndex)
return;
m_columns[e.ColumnIndex].Width = lvResearchPoints.Columns[e.ColumnIndex].Width;
m_columnsChanged = true;
}
示例12: networkListView_ColumnWidthChanged
private void networkListView_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
networkListView.SetLastColumnWidth();
}
示例13: control_ColumnWidthChanged
private void control_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
ColumnHeader column = m_control.Columns[e.ColumnIndex];
m_columnWidths[column.Text] = column.Width;
}
示例14: mappingsListView_ColumnWidthChanged
private void mappingsListView_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e)
{
ColumnHeader column = mappingsListView.Columns[e.ColumnIndex];
if (column == descriptionColumn)
{
if(column.Width < 40)
column.Width = 40;
else if (column.Width > 1000)
column.Width = 1000;
}
else if (column == localPortColumn)
{
if (column.Width != 80)
column.Width = 80;
}
else if (column == desiredPortColumn)
{
if (column.Width != 80)
column.Width = 80;
}
else if (column == statusColumn)
{
if (column.Width != 18)
column.Width = 18;
}
else if (column == publicPortColumn)
{
if (column.Width != 80)
column.Width = 80;
}
}
示例15: lvwProjects_ColumnWidthChanged
private void lvwProjects_ColumnWidthChanged(object sender, ColumnWidthChangedEventArgs e) {
//Größe der ListView Spalten sichern
saveColumnHeaderSizes(lvwProjects);
}