【问题标题】:Disable the mouseover effect on an XCeed WinForms DataGrid?禁用 XCeed WinForms DataGrid 上的鼠标悬停效果?
【发布时间】:2016-03-28 10:49:03
【问题描述】:

我正在使用 Xceed WinForms DataGrid 控件,但似乎无法移除鼠标悬停行高亮效果。我尝试将 DataGrid 更改为只读并将 SelectionMode 更改为 None,但它仍然坚持在鼠标悬停时突出显示该行。

我在文档中找不到任何建议如何执行此操作的内容。

有什么想法吗?

【问题讨论】:

    标签: c# winforms mouseover xceed xceed-datagrid


    【解决方案1】:

    您是否尝试过设置myGrid.DataRowTemplate.OverrideUIStyle = true;,然后设置类似:

    // custom selection colors
    myGrid.SelectionVisualStyle.BackColor = Color.Blue;
    myGrid.SelectionVisualStyle.ForeColor = Color.Yellow;
    
    // custom MouseOver colors
    myGrid.DataRowTemplate.HotVisualStyle.BackColor = Color.Orange;
    myGrid.DataRowTemplate.HotVisualStyle.ForeColor = Color.White;
    

    【讨论】:

      猜你喜欢
      • 2013-03-23
      • 2010-12-04
      • 1970-01-01
      • 1970-01-01
      • 2013-11-23
      • 2011-08-30
      • 2016-09-06
      • 2016-04-26
      • 2013-05-06
      相关资源
      最近更新 更多