Skip to content

How To Close AppWindow's CanResize ? (Windows) #571

Discussion options

You must be logged in to vote

Oh, I missed it. I found the necessary code while searching the source code.

public partial class MainWindow : AppWindow
{
    public MainWindow()
    {
        AvaloniaXamlLoader.Load(this);

#if DEBUG
        this.AttachDevTools();
#endif

        // if u use this porperty, remove minimize and maximize button from titlebar.
        this.ShowAsDialog = true;


        SplashScreen = new MainAppSplashScreen(this);
        TitleBar.ExtendsContentIntoTitleBar = true;
        TitleBar.TitleBarHitTestType = TitleBarHitTestType.Complex;


        Application.Current.ActualThemeVariantChanged += OnActualThemeVariantChanged;
    }
}

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by OmerFarukAkyapak
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant