Ureader.com  
Microsoft software help and Community
   home   |   control panel login   |   archive   |  
 
DotNet
acad.assignment.mngr
academic
adonet
aspnet
aspnet.announcements
aspnet.build.controls
aspnet.caching
aspnet.datagridcontrol
aspnet.mobile
aspnet.security
aspnet.webcontrols
aspnet.webservices
clr
compactframework
component_services
datatools
distributed_apps
drawing
faqs
framework
framework.wmi
general
internationalization
interop
languages.csharp
languages.jscript
languages.vb
languages.vb.controls
languages.vb.data
languages.vb.upgrade
languages.vc
languages.vc.libraries
myservices
odbcnet
performance
remoting
scripting
sdk
security
setup
vjsharp
vsa
webservi.enhancements
webservices
windowsforms
windowsforms.controls
winforms.databinding
winforms.designtime
xml
  
 
date: 29 Jul 2008 01:48:18 +1000,    group: microsoft.public.dotnet.framework.windowsforms        back       


click inside a circle   
I have to draw two circles in a box, first larger and second smaller 
inside the first.

a) I have done this in the paint routine for the panel and it works is 
this the correct spot for drawing images like this?

b) I have to know where a line drawn from inside the smaller circle to a 
mouse click (working) intersects with the outer circle (if it does) and 
if not the inner circle (if it does).  Is there a magic process to work 
this out?

Ta
Ken
date: 29 Jul 2008 01:48:18 +1000   author:   Ken Foskey

Re: click inside a circle   
Hi Ken,

as far as I know, there's no magic method to do this.
you need do some calculation here.

-Jonny

On Jul 28, 11:48 pm, Ken Foskey  wrote:
> I have to draw two circles in a box, first larger and second smaller
> inside the first.
>
> a) I have done this in the paint routine for the panel and it works is
> this the correct spot for drawing images like this?
>
> b) I have to know where a line drawn from inside the smaller circle to a
> mouse click (working) intersects with the outer circle (if it does) and
> if not the inner circle (if it does).  Is there a magic process to work
> this out?
>
> Ta
> Ken
date: Tue, 29 Jul 2008 06:57:27 -0700 (PDT)   author:   jonny

Re: click inside a circle   
This kind of magic is called math. I would try to search for circle line 
intersection in Google and it should return tons of links... Always try 
Google when you have to deal with "classic" calculations...

--
Patrice


"Ken Foskey"  a écrit dans le message de 
groupe de discussion : 488dea42@dnews.tpgi.com.au...
>
> I have to draw two circles in a box, first larger and second smaller
> inside the first.
>
> a) I have done this in the paint routine for the panel and it works is
> this the correct spot for drawing images like this?
>
> b) I have to know where a line drawn from inside the smaller circle to a
> mouse click (working) intersects with the outer circle (if it does) and
> if not the inner circle (if it does).  Is there a magic process to work
> this out?
>
> Ta
> Ken
>
date: Wed, 30 Jul 2008 17:12:53 +0200   author:   Patrice http://www.chez.com/scribe/

Google
 
Web ureader.com


    COPYRIGHT 2007, YARDI TECHNOLOGY LIMITED, ALL RIGHT RESERVE  |   contact us