devexpress GridControl 行指示列图标绘制
Row Indicator Panel
The row indicator panel represents a region displayed at the left edge of the View. The panel contains row indicator cells corresponding to different View sections (the band header panel, the column header panel, data rows, the View footer, etc). The cell relating to the focused row indicates the row state (whether it is in edit mode or has been modified, etc.). When multiple selection is enabled, end-users can click cells and then drag the mouse cursor to another cell to select a range of rows.
The following icons can be displayed within an indicator panel.
- Focused row.
- The focused cell's in-place editor is active.
- The focused row is modified.
- The focused row is a New Item Row.
- The focused row is an Auto Filter Row.
- Indicates the button used to maximize a detail View.
- Indicates the button used to restore a detail View.
- The focused row contains errors.
- A non-focused row contains errors.
The table below lists the main properties affecting element appearance.
Appearance | The GridViewAppearances.HeaderPanel property specifies appearance settings used for painting all indicator cells, except for the cell relating to the band header panel. This cell is painted using the BandedViewAppearances.BandPanel property's settings.
An element's background colors cannot be changed when a View is painted using the Windows XP, Office2003, or any skinning paint style (see the BaseView.PaintStyleNameproperty). |
Custom Draw Event | The GridView.CustomDrawRowIndicator event. |
Visibility | The GridOptionsView.ShowIndicator option. |
Width | The GridView.IndicatorWidth property. |
private void gridView1_CustomDrawRowIndicator(object sender, DevExpress.XtraGrid.Views.Grid.RowIndicatorCustomDrawEventArgs e) { if (e.Info.IsRowIndicator){ DataRow row = gridView1.GetDataRow(e.RowHandle); if (row != null && row.RowError != String.Empty) { e.Info.ImageIndex = -1; e.Painter.DrawObject(e.Info); Rectangle r = e.Bounds; r.Inflate(-1, -1); int x = r.X + (r.Width - imageList1.ImageSize.Width) / 2; int y = r.Y + (r.Height - imageList1.ImageSize.Height) / 2; e.Graphics.DrawImageUnscaled(imageList1.Images[0], x, y); e.Handled = true; } } }
devexpress GridControl 行指示列图标绘制的更多相关文章
- 在DevExpress GridControl的一列中显示图片
作者:jiankunking 出处:http://blog.csdn.net/jiankunking 近期做项目的时候用到了将GridControl中一列设置为PictureEdit类型,然后通过这一 ...
- DevExpress GridControl 后台设置列
/// <summary> /// 初始化GridView /// </summary> /// <param name="gv">GridVi ...
- C# devExpress GridControl 行中行 子行 多级行
在工作中经常会碰到需要做行中行,多级行的情况,不熟的情况下,我也只能试着实现. 命名空间 using DevExpress.XtraEditors.Repository; using System.D ...
- DevExpress GridControl 显示外部图片
如果数据源中只包含图片的链接,如何在DevExpress GridControl的一列中显示外部图片? 要实现该功能,可通过非绑定列的方式来实现.具体实现方法如下: 1. 创建了一个非绑定列并设 ...
- [DevExpress]GridControl 列头绘制Checkbox
关键代码: /// <summary> /// 为列头绘制CheckBox /// </summary> /// <param name="view" ...
- DevExpress GridControl 显示行号、设置行号宽
显示行号类 /// <summary> /// GridView 显示行号 设置行号列的宽度 /// </summary> /// <param name="g ...
- DevExpress实现根据行,列索引来获取RepositoryItem的方法
/// <summary> /// 根据行,列索引来获取RepositoryItem /// </summary> /// <param name="view& ...
- DevExpress GridControl使用(转)
DevExpress GridControl使用 (一)原汁原味的表格展示 Dev控件中的表格控件GridControl控件非常强大.不过,一些细枝末节的地方有时候用起来不好找挺讨厌的.使用过程中,多 ...
- DEVexpress GridControl 属性设置
1. 如何解决单击记录整行选中的问题 View->OptionsBehavior->EditorShowMode 设置为:Click 2. 如何新增一条记录 (1).gridView.Ad ...
随机推荐
- 重温《js权威指南》 第7,8章
第七章 数组 数组是值的有序集合.js数组是无类型的,数组元素可以是任意类型,同一个数组中不同元素也可能有不同的类型.数组可以动态增长或缩减,创建时无须生命那个一个固定的大小并且数组大 ...
- wamp中的phpmyadmin打开出现:#1045 - Access denied for user 'root'@'localhost' (using password: NO)
详细内容: MySQL said: #1045 - Access denied for user 'root'@'localhost' (using password: NO) phpMyAdmin ...
- 如何向AcmeAir注入问题代码
为什么要注入问题代码? AcmeAir的常规代码是为了压测测试准备的,所以绝大部分的操作都是可以在几十毫秒中就可以正常返回的.为了向用户展示我们APM工具可以在源代码级别发现系统潜在问题,我们需要在A ...
- iOS开发--完整项目
完整项目 Phonetic Swift 写的一个 iOS 版的 Phonetic Contacts,功能很多,其中昵称功能非常实用,已在 GitHub 开源并上架 App Store v2ex – v ...
- 当前主流的安卓APP开发IDE
什么是主流的开发安卓APP的方式? 我是去年4月份接触的Android开发,因此特别有感触,可以明显的感受到安卓APP主流开发方式的改变. 去年,2015年年初,各大安卓开发群大部分大牛在用Eclip ...
- CentOS 7:如何安装防火墙?
对于纯净版的CentOS 7,您必须手动安装防火墙.但是你就算安装了防火墙还是不能马上运行它,你需要再做一些操作才能让它工作. 在CentOS 7中按照以下步骤来设置防火墙 第一步,通过yum安装sy ...
- PowerDesigner将PDM导出生成WORD文档
PowerDesigner将PDM导出生成WORD文档 环境 PowerDesigner15 1.点击Report Temlates 制作模板 2.如果没有模板,单击New图标创建.有直接双击进入. ...
- Scala模式匹配和类型系统
1.模式匹配比java中的switch case强大很多,除了值,类型,集合等进行匹配,最常见的Case class进行匹配,Master.scala有大量的模式匹配. Case "_&qu ...
- SpringMVC整合Shiro——(3)
SpringMVC整合Shiro,Shiro是一个强大易用的Java安全框架,提供了认证.授权.加密和会话管理等功能. 第一步:配置web.xml <!-- 配置Shiro过滤器,先让Shiro ...
- hive报错 Another instance of Derby may have already booted the database
刚装好hive后,启动之后showtables;等正常,退出之后再进入,就发现会报错 Caused by: ERROR XSDB6: Another instance ofDerbymay have ...