<Window x:Class="cn.lds.chatcore.pcw.Views.Page.Search"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:cn.lds.chatcore.pcw.Views.Page"
mc:Ignorable="d"
Title="Search" Height="300" Width="300"
AllowsTransparency="True" WindowStyle="None"
Background="Transparent">
<Grid Width="{Binding Width, ElementName=w}" Height="{Binding Height, ElementName=w}">
<Border Corn
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:cn.lds.chatcore.pcw.Views.Page"
mc:Ignorable="d"
Title="Search" Height="300" Width="300"
AllowsTransparency="True" WindowStyle="None"
Background="Transparent">
<Grid Width="{Binding Width, ElementName=w}" Height="{Binding Height, ElementName=w}">
<Border Corn

这篇博客介绍了如何在WPF中实现半透明窗体的效果。通过使用Border和Grid来确保控件不透明,同时利用CornerRadius设置窗口的圆角,并通过DropShadowEffect添加阴影效果,创造出美观而实用的半透明界面。
3632

被折叠的 条评论
为什么被折叠?



