Solved

Replicating object selection frame behavior

Posted on 1998-07-03
4
113 Views
Last Modified: 2013-11-19
I'm looking at adding some functionality to a tool that lays out graphical objects on a view.  I would like to mimic the selection behavior of other commercial applications that highlight selected objects with the hatched frames with points (like PowerPoint, Visio, etc.).  In doing the analysis, I was wondering if anyone else has gone down this path had has some MFC design pattern advise or at least help me avoid any unnecessary pitfalls.  There might even be a good class in a library that does this, but I haven't found it yet.  Suggestions?

Any help is greatly appreciated.... Thanks!

Chris
0
Comment
Question by:ctynes
  • 2
4 Comments
 
LVL 2

Expert Comment

by:lucidity
ID: 1318710
Your best bet would be to go with OLE objects, easy and widely supported. I will make things like creation, selection and layering fairly easy (once you've made the object classes and sub classes anyway)
0
 
LVL 11

Expert Comment

by:mikeblas
ID: 1318711
Huh?  You should use OLE for OLE, not for selection!  And it's often inadequate for more complicated apps--OLE objects always have a rectangular area within their client, and objects you draw aren't always rectangles.

Implementing hatching and rubber-band selections isn't very hard. Look at the paint program from my book for examples on how to do rubber-banding and grab handles.

B ekiM
0
 

Author Comment

by:ctynes
ID: 1318712
Thanks for the reference Mike.  It looks like your book is going to be the ticket for retro-fitting this behavior into this application I'm taking over.  From some reviews I just read, it looks like you have several other ideas I can play off of as well to beef it up.

Chris
0
 
LVL 11

Accepted Solution

by:
mikeblas earned 100 total points
ID: 1318713
Swell.  Good luck with your project.

B ekiM
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Exception Handling is in the core of any application that is able to dignify its name. In this article, I'll guide you through the process of writing a DRY (Don't Repeat Yourself) Exception Handling mechanism, using Aspect Oriented Programming.
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
This tutorial demonstrates a quick way of adding group price to multiple Magento products.

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now