2011-12-07 5 views

답변

5

무엇 :

<Window x:Class="MainWindow" 
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" 
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" 
    Title="MainWindow" Height="350" Width="525"> 
    <Grid> 
     <Label Content="{Binding RelativeSource={RelativeSource AncestorType={x:Type Window}, Mode=FindAncestor}, Path=ActualWidth}"></Label> 
    </Grid> 
</Window> 

는 그냥 ActualWidth 속성을 사용합니다.

3

Width 대신 ActualWidth을 사용하십시오.

5

ActualWidth 너비가 최대화 상태가됩니다. 이것에 대해