Lisp HUG Maillist Archive

RE: CAPI problem: Howto ...

RE: CAPI problem: Howto ...

Hi Dmitri,
thanks for your answer. Please find my comments below.

>| I can imagine two possible solutions:
>| 1. Redirecting the click event. Then the button will never see the
>| event and the enclosing window can handle it.
>|
>| 2. putting a pane with transparent background over the whole window.
>| Then all events should go to that pane and can be handled there.
>| Is one of this solutions possible ?
>| Are there other solutions for that problem ?
>| The application is MS-Windows only and doesn't need to be portable.
>| However, a portable solution is obviously prefered.
>
>The first may be possible with lots of Win32 API hacking around.
>

Yes, i would need to change the wndProc of the enclosing window or
(more brute-force) hang into the Get-Message/dispatch-message loop
and catch all events in question.

>The second is hardly possible since CAPI seems not to support
>transparent background or superimposing widgets.

I'm able to overlay widgets in a grid-layout by another grid-layout
(the trick is that capi seems to draw the :content from the last to the
 first entry). Then maybe (?) i can set the drawing mode to Transparent.
But i would still need the WindowsHandle of the overlayed window. Is there
a way to get this ?

>
>The prettiest solution would be drawing by hand everything
>(including the
>button) on an output-pane. You could also investigate the
>possibility to put
>the button inside a pinboard-layout though this would suffers
>some of the
>flaws you have mentioned above.

The problem here is that for some widget i don't know how they look
(i.e. a text field may have arbitrary text and scroll positions).
I would need to blit the window into an off-screen buffer and then
create a new window with a "picture" of the original one :-(
Is this possible at all in CAPI ?

Kind regards
AHz

Re: CAPI problem: Howto ...

Unable to parse email body. Email id is 2200

Re: CAPI problem: Howto ...

Hello Andreas,

|> The second is hardly possible since CAPI seems not to support 
|> transparent background or superimposing widgets. 
| I'm able to overlay widgets in a grid-layout by another grid-layout 
| (the trick is that capi seems to draw the :content from the last to the
| first entry). Then maybe (?) i can set the drawing mode to Transparent.
| But i would still need the WindowsHandle of the overlayed window. Is
| there a way to get this ? 

Sorry, I've never tried.

|> The prettiest solution would be drawing by hand everything 
|> (including the 
|> button) on an output-pane. You could also investigate the 
|> possibility to put 
|> the button inside a pinboard-layout though this would suffers 
|> some of the 
|> flaws you have mentioned above. 
| The problem here is that for some widget i don't know how they look 
| (i.e. a text field may have arbitrary text and scroll positions). 
| I would need to blit the window into an off-screen buffer and then 
| create a new window with a "picture" of the original one :-( 
| Is this possible at all in CAPI ? 

It should be with Win32 hacking involved.
--
Sincerely,
Dmitri Ivanov
lisp.ystok.ru


Updated at: 2020-12-10 08:57 UTC