如何在VB6中通过三个点绘制圆弧? [英] How to draw an arc through three points in VB6?

查看:302
本文介绍了如何在VB6中通过三个点绘制圆弧?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

我在VB6工作。我必须通过表格上的三点绘制弧线。我不知道如何开始这样做!我有这个问题与你的想法,以帮助我解决它。谢谢。

解决方案

1。要在表单上绘制,您需要将表单子类化为覆盖 Control.OnPaint [ ^ ]。这使您可以访问GDI + 图形 [ ^ ]您用来绘制的对象。



参见用户 - 绘制控件 [ ^ ]或自定义绘图用户控件示例 [ ^ ]。



2.绘制弧形通过3点,请参阅 GDI +中的省略号和弧形 [ ^ ]或 GDI +中的图形路径 [ ^ ]。



跟进:



谢尔盖是对的。 #1适用于Windows窗体(.NET),对您没有帮助。



#2应该仍然有用但是你还需要访问GDI + Graphics 对象。有可能,但用VB6并不容易。这些可能有所帮助:



GDI +简介Visual Basic 6程序员 [ ^ ]



VB6的GDI +包装器 [ ^ ]

Hello,
I am working in VB6. I have to draw an arc through three-point on a Form. I dont know how to start doing this! I have this question with your ideas to help me solve it. Thanks.

解决方案

1. To draw on a Form, you need to subclass the form an override Control.OnPaint[^]. This gives you access to a GDI+ Graphics[^] object that you use to draw.

See User-Drawn Controls[^] or Custom Drawing User Control Sample[^].

2. To draw an arc through 3 points, see Ellipses and Arcs in GDI+[^] or Graphics Paths in GDI+[^].

Follow-up:

Sergey is right. #1 applies to Windows Forms (.NET), and won't help you.

#2 should still work but you still need access to a GDI+ Graphics object. It is possible, but not as easy with VB6. These may help:

A GDI+ Introduction for Visual Basic 6 Programmers[^]

GDI+ wrapper for VB6[^]


这篇关于如何在VB6中通过三个点绘制圆弧?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆