Bootstrap

wpf 窗口联动,实现贴合的可隐藏侧边栏效果

请添加图片描述

<mah:MetroWindow x:Class="MPC.Common.Views.PCMSchemeView"
        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:MPC.Common.Views"
        mc:Ignorable="d"
        xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
        xmlns:mah="http://metro.mahapps.com/winfx/xaml/controls" 
        Title="PCMCtrlView" Height="450" Width="800" 
        WindowStartupLocation="CenterScreen"
        ContentRendered="MetroWindow_ContentRendered"
        LocationChanged="MetroWindow_LocationChanged">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="0.1*"/>
            <RowDefinition/>
        </Grid.RowDefinitions>

        <StackPanel>
            <Button Command="{Binding ExpandButtonCommand}" Width="35" 
                        Height="35" BorderBrush="#FFE2E6BE" 
            
;