|
-
Nov 14th, 2010, 04:37 PM
#1
Thread Starter
Frenzied Member
Logic for filling circles in a rectangle
Hi All,
I am struggling with coding up a bit of logic.
I have a map which I have created zones which are basically rectangles which have the coordinates sorted
eg
Zone 1
Zone 2
Zone 3
I then want to create circles within the rectangles. So for example
Item1, Zone1
Item2, Zone1
Item3, Zone3
Item4, Zone2
Item5, Zone1
So i would like Item 1, 2 and 5 to show up as three circles and when the mouse cursor floats over them to show it. The item list is dynamic and so I am not sure how to get about with this?
Has anyone got an idea?
If you find my thread helpful, please remember to rate me 
-
Nov 14th, 2010, 04:56 PM
#2
Re: Logic for filling circles in a rectangle
You not only want to just draw the circles, but also respond to mouse events. So it should be object instead of just plain graphics.
I recommen you download and install the Visual Basic PowerPacks which has some shape type controls like RectangleShape, OvalShape and LineShape which you can put to use.
-
Nov 14th, 2010, 05:59 PM
#3
Thread Starter
Frenzied Member
Re: Logic for filling circles in a rectangle
How difficult is it to use these powerpacks?
If you find my thread helpful, please remember to rate me 
-
Nov 14th, 2010, 06:02 PM
#4
Thread Starter
Frenzied Member
Re: Logic for filling circles in a rectangle
I've got as far as the rectangle zones, but i need the circles to fill inside these rectangles...
If you find my thread helpful, please remember to rate me 
-
Nov 14th, 2010, 10:34 PM
#5
Re: Logic for filling circles in a rectangle
You might like to follow CodeBank link in my signature and check out my Manipulating GDI+ thread.
-
Nov 15th, 2010, 12:19 PM
#6
Re: Logic for filling circles in a rectangle
 Originally Posted by dinosaur_uk
How difficult is it to use these powerpacks?
If you know how to use a TextBox or Label, this is no different. I think even easier.
-
Nov 15th, 2010, 01:21 PM
#7
Thread Starter
Frenzied Member
Re: Logic for filling circles in a rectangle
Yeah, but i need draw at runtime and the number of circles in the zone is dynamic
If you find my thread helpful, please remember to rate me 
-
Nov 15th, 2010, 05:53 PM
#8
Re: Logic for filling circles in a rectangle
 Originally Posted by dinosaur_uk
Yeah, but i need draw at runtime and the number of circles in the zone is dynamic
If you can add a TextBox to a form at run time you can add a shape.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|