GlassExtendFrameIntoClientArea Method |
Namespace: Ookii.Dialogs
public static void ExtendFrameIntoClientArea( this IWin32Window window, Padding glassMargin )
Exception | Condition |
---|---|
ArgumentNullException | window is . |
NotSupportedException | The current operating system does not support glass, or the Desktop Window Manager is not enabled. |
Use negative margins to create the "sheet of glass" effect where the client area is rendered as a completely glass surface.
The glass area must be filled with either a black brush or the TransparencyKey color in order to display correctly. If the TransparencyKey method is used, clicks in the glass area will "fall through" the window to the window below it. If the black brush method is used, text rendered with the TextRenderer will not display correctly on the glass area (this includes text drawn by most controls). To draw text on the glass area, use DrawCompositedText(IDeviceContext, String, Font, Rectangle, Padding, Color, Int32, TextFormatFlags).
This method needs to be called again if the state of the Desktop Window Manager is toggled.