How do I show the overlay on startup?

WPF Studio, Themes, and Shared Library for WPF Forum

Posted 8 months 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 8 months 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 8 months ago by Kevin Fournier
Avatar

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

The latest build of this product (v22.1.2) was released 3 months ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.