Files
29WxOrder/29WxOrderWpf/MainWindow.xaml
T
2026-06-12 20:13:25 +08:00

74 lines
4.2 KiB
XML

<Window x:Class="_29WxOrderWpf.MainWindow"
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:_29WxOrderWpf"
mc:Ignorable="d" WindowStyle="None" AllowsTransparency="True" Background="Transparent"
Title="MainWindow" Height="450" Width="800" WindowStartupLocation="CenterScreen" Loaded="Window_Loaded">
<WindowChrome.WindowChrome>
<!--边框可拖动范围-->
<WindowChrome CaptionHeight="10" ResizeBorderThickness="5" />
</WindowChrome.WindowChrome>
<Grid Background="AliceBlue">
<Grid.RowDefinitions>
<RowDefinition Height="50"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
</Grid.RowDefinitions>
<Border Grid.RowSpan="10" BorderThickness="1" BorderBrush="Blue"></Border>
<Button Grid.Row="0" Content="x" HorizontalAlignment="Right" Margin="4" VerticalAlignment="Top" Width="20" Height="20" Click="btnClose_Click"/>
<DataGrid Grid.Row="1" HorizontalContentAlignment="Center" Margin="2,0,2,2" RowHeight="60" x:Name="dgOrder" Grid.ColumnSpan="2"
HorizontalGridLinesBrush="LightGray" VerticalGridLinesBrush="LightGray" CanUserDeleteRows="False" CanUserAddRows="False">
<DataGrid.CellStyle>
<Style TargetType="DataGridCell">
<Setter Property="Background" Value="White"/>
<Style.Triggers>
<Trigger Property="IsSelected" Value="True">
<Setter Property="Background" Value="AliceBlue"/>
<Setter Property="BorderThickness" Value="0"/>
<Setter Property="Foreground" Value="Black"/>
</Trigger>
</Style.Triggers>
</Style>
</DataGrid.CellStyle>
<DataGrid.RowStyle>
<Style TargetType="DataGridRow">
<Setter Property="Background" Value="White"/>
<Style.Triggers>
<Trigger Property="IsSelected" Value="True">
<Setter Property="Background" Value="AliceBlue"/>
</Trigger>
</Style.Triggers>
</Style>
</DataGrid.RowStyle>
<DataGrid.Columns>
<DataGridCheckBoxColumn Binding="{x:Null}" ClipboardContentBinding="{x:Null}" Width="50"/>
<DataGridTemplateColumn ClipboardContentBinding="{x:Null}" Width="*" Header="订单编号"/>
<DataGridTemplateColumn Width="*" Header="图标">
<DataGridTemplateColumn.CellTemplate>
<DataTemplate>
<Grid>
<Grid.RowDefinitions>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="auto"></RowDefinition>
<RowDefinition Height="*"></RowDefinition>
</Grid.RowDefinitions>
<Border Grid.Row="1" HorizontalAlignment="Center" Width="Auto" Height="26" Padding="0" Margin="5" CornerRadius="5" Background="LightYellow" BorderBrush="Orange" BorderThickness="1">
<Label HorizontalAlignment="Center" Width="Auto" Content="店铺待发货" Foreground="Orange"></Label>
</Border>
<TextBox Grid.Row="2" HorizontalAlignment="Center" Width="Auto" Height="20" Background="Transparent" IsReadOnly="True" Text="收货地址 吕* 1********** 江苏省 镇江市 京口区" BorderThickness="0"></TextBox>
</Grid>
</DataTemplate>
</DataGridTemplateColumn.CellTemplate>
</DataGridTemplateColumn>
</DataGrid.Columns>
</DataGrid>
</Grid>
</Window>