中国程序员联盟 正在重新改版中ing 不便之处还请见谅 改版后将内容涉及java delphi .net php
 
  首页 | 数据库开发 | 网络通讯 | 多线程 | 多媒体开发 | 图像处理 | 程序人生 | 系统函数 | 控件开发 | Web服务
 
  当前位置:笨鱼delphi技术网>控件开发>控件使用>文章内容

delphi 在GRID画一个没有滚动条的背景图

来源:国外 关于:Tomas Rutkauskas 发布时间:2007-07-19   [收藏] [推荐]
This should get you started:
TExtDrawGrid = class(TDrawGrid)
protected
  procedure WMEraseBkGnd(var Msg: TWMEraseBkGnd); message WM_ERASEBKGND;
public
end;
procedure TExtDrawGrid.WMEraseBkGnd(var Msg: TWMEraseBkGnd);
begin
  Canvas.Draw(ClientRect.Left, ClientRect.Top, TheBackgroundBitMap);
end;
Setting the DefaultDrawing property to false will prevent the grid from overwriting the back ground with standard cell display. You can decide what gets drawn on top of the background for any given cell. Maybe override the paint method to clean up before the rest gets slapped on top.

[浏览: 次]   
上一篇:delphi Delphi如何处理UNIX文件存储   下一篇:delphi 显示GRID单Cell框的Hint
[收藏] [推荐] [返回顶部] [打印本页] [关闭窗口]  
    评论加载中…
google adsense热点文章
·delphi treeview 使用
·delphi delphi下对象类别检查
·delphi 组件序列化
·delphi 如何在DBGRID里添加行序号
·delphi 组件用户自定义设计期工具
·delphi 显示GRID单Cell框的Hint
·delphi 如何保存属性到运行期使用(上)
·delphi 组件序列化
·delphi 如何将系统所有菜单列到树上Tre
·delphi 如何将属性在设计期保存到DFM文
·delphi 如何保存属性到运行期使用(下)
·delphi VCL控件机制与VCL.net控件机制
     delphi技术网 | firefox 下载 | Avant Browser下载 | dedecms 技术网 | drupal 爱好者 | php 技术网
  Copyright@www.delphichm.com,2006-2009.All Rights Reserved.
 
程序员联盟 | delphi Java .net|QQ:707102932