![]() To enable blur by using DwmExtendFrameIntoClientArea, use the MARGINS structure to indicate how much to extend into the client area. This functionality is exposed by the DwmExtendFrameIntoClientArea function. This is useful when you apply the blur effect behind a window with a docked toolbar or visually separate controls from the rest of an application. Extending the Window Frame into the Client AreaĪn application can extend the blur of the window frame into the client area. Therefore, be careful when you apply a blur effect to a subregion. This can cause an unexpected transparency in the nonblurred region of a window. When you apply the blur-behind effect to a subregion of the window, the alpha channel of the window is used for the nonblurred area. To apply the blur behind a subregion, apply a valid region handle (HRGN) to the hRgnBlur member of the DWM_BLURBEHIND structure and add the DWM_BB_BLURREGION flag to the dwFlags member. The following image illustrates the blur-behind effect applied to the whole window. This tells the DWM to apply the blur behind the whole window. Note that NULL is specified in the hRgnBlur parameter. Hr = DwmEnableBlurBehindWindow(hwnd, &bb) Create and populate the blur-behind structure. The following example function, EnableBlurBehind, illustrates how to apply the blur-behind effect to the whole window. The API used in this scenario is the DwmEnableBlurBehindWindow function, which makes use of the DWM Blur Behind Constants and the DWM_BLURBEHIND structure. This enables applications to add styled path and search bars that are visually separate from the rest of the application. Extending the Window Frame into the Client AreaĪdding Blur to a Specific Region of the Client AreaĪn application can apply the blur effect behind the whole client region of the window or to a specific subregion.Adding Blur to a Specific Region of the Client Area.This topic discusses the following client blur-behind scenarios that the DWM enables. Areas that would typically render with the transparent glass effect on other Windows editions are rendered as opaque.īeginning with Windows 8, calling this function doesn't result in the blur effect, due to a style change in the way windows are rendered. Windows Vista Home Basic edition does not support the transparent glass effect.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |