B
Ben Taylor
Hi,
I am building an ActiveX control, which I would like NOT
to be windowless (e.g. the common dialog control in Visual
Basic being an example of one that is windowless, I don't
want one like this), i.e. I want it to draw and have size,
etc. but be largely transparent. I can sort of mimic
transparency by using TranslateColor(AmbientBackColor())
but this doesn't take into account the fact that the
developer using it might want to have, say, static text
behind my control.
So what I want to do which I would appreciate any help
anybody can possibly give me, is *ideally* to create a
bitmap which contains the bits behind my control - I'm
lost as to where to start though, I'm really new in C++,
my previous language is VB. I could then BitBlt parts of
this bitmap to my control's window, so it would appear
invisible but just displaying the same pixels as the
background in that position.
Does anybody know how to do this, is it a simple function
or does it require complex subclassing or hooks or
something? I'd love to learn how to do this if it is but
please explain it as I have only been at this language for
a few months and am still picking it up.
Also, I might be pusing it here, but aswell as that, is
there an easy way of propogating click events, etc.
through to any controls which may be beneath mine? (If
this sounds really difficult even for you guys please let
me know then I'll know not to bother trying!)
I am building an ActiveX control, which I would like NOT
to be windowless (e.g. the common dialog control in Visual
Basic being an example of one that is windowless, I don't
want one like this), i.e. I want it to draw and have size,
etc. but be largely transparent. I can sort of mimic
transparency by using TranslateColor(AmbientBackColor())
but this doesn't take into account the fact that the
developer using it might want to have, say, static text
behind my control.
So what I want to do which I would appreciate any help
anybody can possibly give me, is *ideally* to create a
bitmap which contains the bits behind my control - I'm
lost as to where to start though, I'm really new in C++,
my previous language is VB. I could then BitBlt parts of
this bitmap to my control's window, so it would appear
invisible but just displaying the same pixels as the
background in that position.
Does anybody know how to do this, is it a simple function
or does it require complex subclassing or hooks or
something? I'd love to learn how to do this if it is but
please explain it as I have only been at this language for
a few months and am still picking it up.
Also, I might be pusing it here, but aswell as that, is
there an easy way of propogating click events, etc.
through to any controls which may be beneath mine? (If
this sounds really difficult even for you guys please let
me know then I'll know not to bother trying!)