x:Class="NonRectangularWindowSample.NonRectangularWindow"

  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

  Title="NonRectangularWindowSample" SizeToContent="WidthAndHeight"

 MouseLeftButtonDown="NonRectangularWindow_MouseLeftButtonDown"

 WindowStyle="None"

 AllowsTransparency="True"

 Background="Transparent">

 


   

   


     

       

         

         

         

         

       


     


     

       

         

           

           

           

           

           

           

           

           

           

           

           

         


       


     


   


   

   


   

   


 





using System;

using System.Windows;

using System.Windows.Input;


namespace NonRectangularWindowSample {


  public partial class NonRectangularWindow : Window {


    public NonRectangularWindow() {

      InitializeComponent();

    }


    void NonRectangularWindow_MouseLeftButtonDown(object sender, MouseButtonEventArgs e) {

      this.DragMove();

    }


    void closeButtonRectangle_Click(object sender, RoutedEventArgs e) {

      this.Close();

    }

  }

}

 

arrow
arrow
    全站熱搜

    狼翔月影 發表在 痞客邦 留言(0) 人氣()