Delphi 从PaintBox拷贝一部分内容到TBitmap


本文整理自网络,侵删。

 将指定的TPaintBox内容(假如为paintbox1)拷贝到一个TBitmap(如Bitmap),可以这么做

Bitmap.Width := PaintBox1.Width;
Bitmap.Height := PaintBox1.Height;
BitBlt(Bitmap.Canvas.Handle,
  0,
  0,
  Bitmap.Width,
  Bitmap.Height,
  PaintBox1.Canvas.Handle,
  0,
  0,
  SRCCOPY);

相关阅读 >>

Delphi 查看dpr文件

Delphi tbutton.onclick 匿名函数用法

Delphi tapplication大全

Delphi dll 字符串传递例子

Delphi在网格cxgrid的左上角放置一个按钮

Delphi windows服务控制单元

Delphi decodedate、decodetime ... decodedatetime ... 分解时间

Delphi将xm音乐文件嵌入自己的程序

Delphi如何在tmemo控件光标当前位置插入字符串

Delphi tidhttp抓取页面信息

更多相关阅读请进入《Delphi》频道 >>



打赏

取消

感谢您的支持,我会继续努力的!

扫码支持
扫码打赏,您说多少就多少

打开支付宝扫一扫,即可进行扫码打赏哦

分享从这里开始,精彩与您同在

评论

管理员已关闭评论功能...