高原之上原文TreeList 选中节点时图标状态和背景色

     // 给TreeList加SelectImage
this.treelArea.SelectImageList = imglCustom;
// 去掉选中节点时的虚框
this.treelArea.OptionsView.ShowFocusedFrame;
// 设置选中时节点的背景色
this.treelArea.Appearance.FocusedCell.BackColor = System.Drawing.Color.LightSteelBlue;
this.treelArea.Appearance.FocusedCell.BackColor2 = System.Drawing.Color.SteelBlue;
this.treelArea.Appearance.FocusedCell.Options.UseBackColor = true;
// 选中时会把节点中没显示完全的信息全部显示
this.treelArea.Appearance.FocusedCell.Options.UseTextOptions = true;
this.treelArea.Appearance.FocusedCell.TextOptions.WordWrap = DevExpress.Utils.WordWrap.Wrap; /// <summary>
/// Handles the GetSelectImage event of the treelArea control.
/// 设置SelectImage的状态,如果是选中的则换成另选中时应该显示的图标
/// </summary>
/// <param name="sender">The source of the event.</param>
/// <param name="e"> instance containing the event data.</param>
private void treelArea_GetSelectImage(object sender, DevExpress.XtraTreeList.GetSelectImageEventArgs e)
{
e.NodeImageIndex = e.Node.Expanded ? 0 : e.Node.Nodes.Count > 0 ? 1 : 2; if (e.FocusedNode)
{
e.NodeImageIndex += 3;
}
}

[转] TreeList 当前节点图标和背景色设置的更多相关文章

  1. Dev TreeList 添加节点图标问题

    1. 在设计界面添加imageCollection控件,在属性页设置图标(可Load from disk,也可从Load from dev gallery) 2. TreeList控件有一个叫做Cus ...

  2. DELPHI TreeView 文件目录树和 设置节点图标 完整

        DELPHI TreeView 文件目录树和 设置节点图标   下载地址 http://download.csdn.net/detail/teststudio/6448293     需要制作 ...

  3. TreeView设置节点图标

    TreeView设置节点图标 没子节点的设置其图标为 0 有节点的设置其图标为 1 procedure TForm1.Button1Click(Sender: TObject);var   i:Int ...

  4. WinForm------TreeList修改节点图标和按钮样式

    转载: https://documentation.devexpress.com/#WindowsForms/DevExpressXtraTreeListTreeList_CustomDrawNode ...

  5. div 背景色设置_DIV背景颜色设置

    DIV 背景色设置篇-div背景颜色设置篇 一.div标签内直接设置背景颜色   -   TOP <div style="background:#000; color:#FFF&quo ...

  6. Android ListView的item背景色设置以及item点击无响应等相关问题

    Android ListView的item背景色设置以及item点击无响应等相关问题 在Android开发中,listview控件是非常常用的控件,在大多数情况下,大家都会改掉listview的ite ...

  7. ztree删除某个节点下的全部子节点后,父节点图标还是文件夹

    <script type="text/javascript"> //删除节点 zTree.removeNode(treeNode); //获取删除节点的父节点 var ...

  8. 关于POI 中单元格背景色设置(转)

    关于POI 中单元格背景色设置(转)   csdn 中找到了用Apache POI 实现单元格背景色的小例子 我用了JDK6 + POI 3.17 ,调试中报错 最终将 CellStyle.SOLID ...

  9. eclipse中的字体大小设置和背景色设置

    1.字体大小设置 在basic下选择最后一个TextFont 护眼背景色设置 添加到自定义颜色后点确定 最后一步点apply

随机推荐

  1. Boost简介

    原文链接:  吴豆豆http://www.cnblogs.com/gdutbean/archive/2012/03/30/2425201.html Boost库 Boost库是为C++语言标准库提供扩 ...

  2. hashtable用法

    import java.util.Hashtable; public class HashTable { public static void main (String[] args) { Hasht ...

  3. 在AngularJS中学习javascript的new function意义及this作用域的生成过程

    慢慢入门吧,不着急. 至少知道了controller和service的分工. new function时,隐含有用this指向function的prototype之意. 这样,两个JAVASCRIPT ...

  4. jquery cookie 用法

    jquery cookie 用法 $.cookie("name","value","options")  当不设置options时,此coo ...

  5. lintcode: 二叉查找树中搜索区间

    题目 二叉查找树中搜索区间 给定两个值 k1 和 k2(k1 < k2)和一个二叉查找树的根节点.找到树中所有值在 k1 到 k2 范围内的节点.即打印所有x (k1 <= x <= ...

  6. Hibernate逍遥游记-第10章 映射继承关系-003继承关系树中的每个类对应一个表(joined-subclass)

    1. 2. <?xml version="1.0"?> <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate ...

  7. apache缓存

    http://www.t086.com/article/4256 http://www.360doc.com/content/09/0928/13/41237_6551659.shtml

  8. redis twitter

    http://redis.io/topics/twitter-clone 翻译:http://my.oschina.net/Twitter/blog/287539

  9. C Socket Programming for Linux with a Server and Client Example Code

    Typically two processes communicate with each other on a single system through one of the following ...

  10. Ubuntu 12.04搭建MTK 6577 安卓开发环境

    Ubuntu 12.04搭建 MTK 6577安卓开发环境 1.       下载并安装Vmware虚拟机: 2.       下载并在虚拟机上安装Ubuntu 12.04 iso 安装包:下载地址: ...