How do I show the overlay on startup?

WPF Studio, Themes, and Shared Library for WPF Forum

Posted 2 years ago by Kevin Fournier
Version: 21.1.3
Avatar

I want the overlay to be visible on startup, but setting the IsOverlayVisible property to true doesn't seem to affect anything. How can I make the overlay appear when the window first appears?

Comments (2)

Answer - Posted 2 years ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hi Kevin,

Thank you for writing.  The problem here is that the WindowChrome doesn't fully initialize until when the Window.SourceInitialized event fires.

I found that adding this line in our WindowChromeProcessingOverlay sample's MainWindow constructor after InitializeComponent, the overlay did show:

this.Loaded += (sender, e) => WindowChrome.SetIsOverlayVisible(this, true);

It delays showing the overlay until the Window.Loaded event.

That being said, we will update the code for the upcoming 22.1 version to allow the overlay to be made visible without having to delay to the Loaded event.


Actipro Software Support

Posted 2 years ago by Kevin Fournier
Avatar

This work around gets me up and running. Thanks, guys.

The latest build of this product (v24.1.1) was released 2 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.