I'm using Delphi XE2, and I like glass effects, and I want to "cut" glass as in Windows 7 tablet tools. If you also know how cut a button I'll be happy if you tell me how.
Thanks
I'm using Delphi XE2, and I like glass effects, and I want to "cut" glass as in Windows 7 tablet tools. If you also know how cut a button I'll be happy if you tell me how.
Thanks
Drawing in the top area is simply a matter of using a glass frame and painting in the non-client area, or alternatively, using the DwmExtendFrameIntoClientArea API.
The best code sample I have seen for this is the VCL "Ribbon" control, which provides a "QAT" (quick Access toolbar) area, painted in the "non client area".
Note that the author has to think not only about how to render when Vista/Win7 systems which have Glass ON, but also has to decide how to render on WinXp, Win7 and Vista when the Themes engine is off. There is quite a bit of logic in the Vcl.Ribbon.pas
(or just Ribbon.pas if you're in XE or earlier) unit dedicated to that.
Look at procedure TCustomRibbonQuickAccessPopupToolbar.NCPaint(DC: HDC);
in the Vcl Ribbon sources.
Drawing a non-rectangular "extended area" that protrudes from the bottom is probably a matter of applying a custom window clipping region.
UpdateLayeredWindow
? Will this really do the trick ? –
Ugh Did you mean you want shaped forms? If so
could help. I imagine this will work on Windows 7 (note Remy's comment in the answer).
hth
© 2022 - 2024 — McMap. All rights reserved.
here's
one interesting reading about Desktop Window Manager and some of its functions, but I don't think there's an answer to your question there (that's why OT :) – UghTinyURL
. – Ughhere
orhere
orthere
) but I found no solution for it. I'm pretty sure there would be an example in some C language at least onCodeProject
, but nothing I can find. Maybe I'm missing something or it's undocumented feature; hard to say, but I don't want to give it up. – Ugh