Solved

Delphi Programming question

Posted on 1997-07-09
2
142 Views
Last Modified: 2010-04-06
Hi!

I've derived a component from aa tpaintbox which draws a shadow under each of it's childs... It runs well, but I would like to repaint some parts of the shadows when one child-windows changes it's position, size or dissapeares at all.

How can I get a notification when a child-window changes it's bounds?

It's not possible to use the methods provided by the child-windows. I need them for other purposes. I read the windows api, but didn't find a message which does what I want.

any ideas?

  nils pipenbrinck

Thank you.
0
Comment
Question by:nils pipenbrinck
2 Comments
 
LVL 1

Accepted Solution

by:
ygolan earned 0 total points
ID: 1338502
Nils,

To get a notification when a child is destroyed, override the Notification method of your paint control - it will be called wheneven a component is added/removed from the form.

To detect when a child is resized, you need to subclass its window, and capture the WM_WINPOSCHANGED message. Email me if you need source code which will help you to perform the subclassing at ygolan@hyperact.com.

0
 
LVL 4

Author Comment

by:nils pipenbrinck
ID: 1338503
thank you..

your answer was really excelent..

Nils
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

828 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