當前位置: 首頁>>代碼示例>>C#>>正文


C# Forms.ColumnWidthChangingEventArgs類代碼示例

本文整理匯總了C#中System.Windows.Forms.ColumnWidthChangingEventArgs的典型用法代碼示例。如果您正苦於以下問題:C# ColumnWidthChangingEventArgs類的具體用法?C# ColumnWidthChangingEventArgs怎麽用?C# ColumnWidthChangingEventArgs使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


ColumnWidthChangingEventArgs類屬於System.Windows.Forms命名空間,在下文中一共展示了ColumnWidthChangingEventArgs類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: OnColumnWidthChanging

        protected virtual void OnColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
        {
            if ( e.ColumnIndex != ColumnIndex ) return;

            e.Cancel = true;
            e.NewWidth = ListView.Columns[e.ColumnIndex].Width;
        }
開發者ID:ChrisDodgeRR,項目名稱:RaceTiming,代碼行數:7,代碼來源:ListViewButtonColumn.cs

示例2: lv_cancelResize

 private void lv_cancelResize(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.ColumnIndex == 1)
       {
     e.Cancel = true;
     e.NewWidth = 0;
       }
 }
開發者ID:pavlin-policar,項目名稱:SimpleMailClient,代碼行數:8,代碼來源:wuc_inbox.cs

示例3: listView_ColumnWidthChanging

 private void listView_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (TotalColWidth > ClientSize.Width)
     {
         e.Cancel = true;
         e.NewWidth = ClientSize.Width - (TotalColWidth - Columns[e.ColumnIndex].Width);
     }
     treeView.Refresh();            
 }
開發者ID:fbmly007,項目名稱:3dsexplorer,代碼行數:9,代碼來源:TreeListView.cs

示例4: OnColumnWidthChanging

		void OnColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
		{
			// Don't allow the user to display the first column (item name).
			if (e.ColumnIndex == columnIndex)
			{
				e.Cancel = true;
				e.NewWidth = 0;
			}
		}
開發者ID:Zaharkov,項目名稱:SteamKit,代碼行數:9,代碼來源:ListViewColumnHider.cs

示例5: OnColumnWidthChanging

 protected override void OnColumnWidthChanging(ColumnWidthChangingEventArgs e)
 {
     if (!AllowChangeHeaderWidth)
     {
         e.Cancel = true;
         e.NewWidth = this.Columns[e.ColumnIndex].Width;
     }
     base.OnColumnWidthChanging(e);
 }
開發者ID:panshuiqing,項目名稱:winform-ui,代碼行數:9,代碼來源:ListViewEx.cs

示例6: Current_List_ColumnWidthChanging

 private void Current_List_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.ColumnIndex == lockColumnIndex)
     {
         //Keep the width not changed.
         e.NewWidth = this.Current_List.Columns[e.ColumnIndex].Width;
         //Cancel the event.
         e.Cancel = true;
     }
 }
開發者ID:koeqatel,項目名稱:Sander-Productions-Media-player,代碼行數:10,代碼來源:PlayLists.cs

示例7: listView1_ColumnWidthChanging

 private void listView1_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     this.DatatreeView.Focus();
     this.DatatreeView.Invalidate();
 }
開發者ID:zwq194,項目名稱:MagicMongoDBTool,代碼行數:5,代碼來源:TreeViewColumns.cs

示例8: LV_Entries_ColumnWidthChanging

 /// <summary>
 /// Prevent user from changing column widths
 /// </summary>
 private void LV_Entries_ColumnWidthChanging(
     object sender, ColumnWidthChangingEventArgs e)
 {
     e.Cancel = true;
     e.NewWidth = lvManga.Columns[e.ColumnIndex].Width;
 }
開發者ID:Nagru,項目名稱:Manga-Organizer,代碼行數:9,代碼來源:Main.cs

示例9: listRestorePoint_ColumnWidthChanging

 /// <summary>
 /// listRestorePoint ColumnWidthChanging event handler.
 /// Sets the [0] column width to 0.
 /// </summary>
 /// <param name="sender"></param>
 /// <param name="e"></param>
 void listRestorePoint_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.ColumnIndex == 0)
     {
         e.NewWidth = 0;
         e.Cancel = true;
     }
 }
開發者ID:nullkuhl,項目名稱:fsu-dev,代碼行數:14,代碼來源:FormRestorePoint.cs

示例10: InventoryList_ColumnWidthChanging

 private void InventoryList_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.ColumnIndex == 0)
     {
         e.NewWidth = this.InventoryList.Columns[0].Width;
         e.Cancel = true;
     }
 }
開發者ID:jmazzola,項目名稱:SCMBot,代碼行數:8,代碼來源:Main.cs

示例11: OnColumnWidthChanging

		protected virtual void OnColumnWidthChanging (ColumnWidthChangingEventArgs e)
		{
			ColumnWidthChangingEventHandler cwceh = (ColumnWidthChangingEventHandler) (Events[ColumnWidthChangingEvent]);
			if (cwceh != null)
				cwceh (this, e);
		}
開發者ID:KonajuGames,項目名稱:SharpLang,代碼行數:6,代碼來源:ListView.cs

示例12: lvTaskList_ColumnWidthChanging

 private void lvTaskList_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.NewWidth < MIN_WIDTH)
     {
         e.Cancel = true;
         e.NewWidth = lvTaskList.Columns[e.ColumnIndex].Width;
     }
 }
開發者ID:riverstore,項目名稱:syncsharp,代碼行數:8,代碼來源:AutoRunForm.cs

示例13: lstvList_ColumnWidthChanging

 //-------------------------------------------------------------------------------
 //
 private void lstvList_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
 {
     if (e.ColumnIndex == 0) { // 畫像部分は動かせないようにする
         e.NewWidth = 52;
         e.Cancel = true;
     }
 }
開發者ID:tomfuru,項目名稱:StarlitTwit,代碼行數:9,代碼來源:FrmDispUsers.cs

示例14: ltvProdutos_ColumnWidthChanging

 private void ltvProdutos_ColumnWidthChanging(object sender, ColumnWidthChangingEventArgs e)
              => MyListView.ColumnWidthChanging(e, ltvProdutos);
開發者ID:mikemajesty,項目名稱:padariaterminalv2,代碼行數:2,代碼來源:frmTerminal.cs

示例15: OnColWidthChanging

 //拖動Head的時候,處理需要隱藏的列。
 void OnColWidthChanging ( object sender , ColumnWidthChangingEventArgs e )
 {
     foreach ( int nCol in _lstColHide )
     {
         if (e.ColumnIndex == nCol && e.NewWidth > 0)
         {
             e.NewWidth = 0;
             e.Cancel = true;
         }
     }
 }
開發者ID:cheng521yun,項目名稱:https---github.com-frontflag-FTMZ_CY,代碼行數:12,代碼來源:XListView2.cs


注:本文中的System.Windows.Forms.ColumnWidthChangingEventArgs類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。