home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!sunic!aun.uninett.no!nuug!falcon!lfosdal
- From: lfosdal@falcon.no (Lars Fosdal)
- Newsgroups: comp.lang.pascal
- Subject: Re: Dragging an object in TPW: how?
- Message-ID: <4H1yXB3w165w@falcon.no>
- Date: Tue, 26 Jan 93 08:14:02 MET
- References: <1993Jan25.112041.16368@genes.icgeb.trieste.it>
- Organization: Falcon Information Services AS, Oslo, Norway
- Lines: 30
-
- oberto@genes.icgeb.trieste.it (Jacques Oberto) writes:
-
- > The question is: how to implement graphical object selection and
- > dragging (with the mouse) in TPW 1.5. I went through every
- > Borland manual w/o success. There must be some API functions to
- > do that but which ones.
-
- Unfortunatly there is no API for graphical object selection in
- Windows (or TPW/BPW). There are mouse click, drag, release messages,
- but all "objects" you put on screen (lines, ellipes, boxes, etc.) are
- not really objects, just a bitmapped images of the objects.
-
- To implement object selection/dragging, you must design your own
- proximity control (which object did the user click on, if any) and
- select draw / drag redraw. I've done it, and it's a pain.
-
- For proxmitity control, you might want to use PtInRect and PtInRegion
- together with a collection/linked list of your drawing objects.
-
- If you'd like to examine third party libraries for TPW, you could look
- at ObjectGraphics(tm) from Whitewater, which have implemented true object-
- based select/drag. It's not fantastic, but it works, and comes with source
- (price is approx. US$ 250.- ).
-
- Lars F.
- --
- | Mr.Lars Fosdal, Software Developer, Financial Analysis Systems |
- | Falcon Information Services AS, Stranden 1, N-0250 Oslo, Norway |
- | -> E-mail:lfosdal@falcon.no Tel:+47 22831310 Fax:+47 22831290 |
- +- All opinions are personal and does not reflect company policy -+
-