Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsVB SyntaxEnterprise DevelopmentDatabase AccessControlsCOMWin APICrystal ReportDeploymentGeneralGeneral 2
Related Topics
VB.NET / ASP.NETMS SQL ServerMS AccessOther Database ProductsMore Topics ...

VB Forum / General / November 2004



Tip: Looking for answers? Try searching our database.

Help please: activate and resize

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
try try again - 30 Nov 2004 15:49 GMT
Help appreciated.  How do I build the functionality, such as found in Visio
etc., to enable selecting (activating) something like a rectangle or other
shape, and then resize and move the shape?  Where/how do the mouse pointer
changes (from default to hand, double-arrow, etc.) happen?  I want to give
this functionality to the user to allow resizing and moving simple shapes.
Mike D Sutton - 30 Nov 2004 16:30 GMT
> Help appreciated.  How do I build the functionality, such as found in Visio
> etc., to enable selecting (activating) something like a rectangle or other
> shape, and then resize and move the shape?  Where/how do the mouse pointer
> changes (from default to hand, double-arrow, etc.) happen?  I want to give
> this functionality to the user to allow resizing and moving simple shapes.

Each shape would be a class instance that encapsulates how it draws itself to the display, knows it bounds rectangle and can
'hit-test' itself for user interaction.  You then have a second object that contains a list of these shapes that has the ability to
hit test all of them (simply by calling the hit-test method of each one) and manages the mouse pointer depending on what was 'hit'
(either selecting/deselecting or on one of it's control handles.)
Since your second message to this group requests something similar in VB.NET code I'm assuming that this is also in .NET so you'll
need to post a more appropriate group for more assistance on the implementation of such an object model, have a look here for some
groups/pages you may want to try
Http://EDais.mvps.org/DotNet/
Hope this helps,

   Mike

- Microsoft Visual Basic MVP -
E-Mail: EDais@mvps.org
WWW: Http://EDais.mvps.org/
Ken Halter - 30 Nov 2004 16:32 GMT
> Help appreciated.  How do I build the functionality, such as found in
> Visio
> etc., to enable selecting (activating) something like a rectangle or other
> shape, and then resize and move the shape?  Where/how do the mouse pointer
> changes (from default to hand, double-arrow, etc.) happen?  I want to give
> this functionality to the user to allow resizing and moving simple shapes.

Here's a start....

Regions (Clickable Shapes) Demo
http://www.mvps.org/vbvision/Sample_Projects.htm

Signature

Ken Halter - MS-MVP-VB - http://www.vbsight.com
Please keep all discussions in the groups..

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.