在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
IGDI+是一个免费开源封装微软GDI+功能的Delphi库,该库使得可以用Delphi语言代码快速简短的实现复杂GDI+应用程序。 安装方法:
procedure TForm1.FormPaint(Sender: TObject);
var AGraphics: IGPGraphics; APen: IGPPen; AFont: IGPFont; ABrush: IGPSolidBrush; rc: TPoint; begin AGraphics := TGPGraphics.Create(Canvas); AGraphics.SmoothingMode := SmoothingModeAntiAlias;//指定平滑(抗锯齿) AGraphics.TextRenderingHint := TextRenderingHintAntiAlias;//指定使用过程中呈现的文本采用反走样 APen := TGPPen.Create($FF000000,3); AGraphics.DrawLine(APen,5,5,100,100); APen.Color := $FF0000FF; APen.Width := 2; AGraphics.DrawEllipse(APen,120,5,100,100); Canvas.Font.Name := '微软雅黑'; Canvas.Font.Size := 13; AFont := TGPFont.Create(Canvas.Handle); ABrush := TGPSolidBrush.Create($FFFF0000); rc.X := 10; rc.Y := 150; AGraphics.DrawString('无幻博客'+#13#10+'http://blog.csdn.net/akof1314',AFont,rc,ABrush); end; 3.运行结果如下图所示: IGDI+库下载:
http://blog.csdn.net/akof1314/article/details/6205578 |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论