zoukankan      html  css  js  c++  java
  • WPF(001):Control.Dock以死,请用DockPanel.

    <DockPanel xmlns="http://schemas.microsoft.com/2003/xaml">

      
    <Border Background="LightBlue" DockPanel.Dock="Top">

        
    <Text FontSize="14" FontStyle="italic">This is Header</Text>

      
    </Border>

      
    <Border DockPanel.Dock="Bottom" Background="LightYellow">

        
    <Text FontSize="14" FontStyle="italic">This is Footer</Text>

      
    </Border>

      
    <Border DockPanel.Dock="Left" Background="#D6C8CC">

        
    <DockPanel>

          
    <Text Margin="5" DockPanel.Dock="Top" FontSize="20">Best Sites</Text>

          
    <HyperLink Margin="5" DockPanel.Dock="Top" NavigateUri="http://blog.joycode.com">

            Visit blog.joycode.com

          
    </HyperLink>

          
    <HyperLink Margin="5" DockPanel.Dock="Top" NavigateUri="http://msdn.microsoft.com">

            Visit msdn.microsoft.com

          
    </HyperLink>

        
    </DockPanel>

      
    </Border>

      
    <Border DockPanel.Dock="Fill">

        
    <DockPanel>

          
    <FlowPanel DockPanel.Dock="Top">

            
    <Button Height="20px" Width="80px" Margin="5,5,10,10">Sign In</Button>

            
    <Button Height="20px" Width="90px" Margin="5,5,10,10">Sign Out</Button>

          
    </FlowPanel> 

          
    <Border DockPanel.Dock="Fill" Background="LightGreen">

            
    <DockPanel>

              
    <Text DockPanel.Dock="Top" Margin="0,10,0,15" FontSize="15">Please read the poem below and answer questions:</Text>

              
    <TextPanel FontSize="14" Background="LightGreen" Foreground="Blue">

               Dock Sample

              
    </TextPanel>              

            
    </DockPanel>

          
    </Border>

        
    </DockPanel>

      
    </Border>

    </DockPanel>

    ----------------------------------- http://www.cnblogs.com/rock_chen/
  • 相关阅读:
    HDU 4396
    Vijos1603 迷宫
    BZOJ1087 [SCOI2005] 互不侵犯King
    BZOJ2208 [JSOI2010] 连通数
    BZOJ1051 [HAOI2006] 受欢迎的牛
    BZOJ2751 [HAOI2012] 容易题(easy)
    BZOJ1015 [JSOI2008] 星球大战starwar
    BZOJ1012 [JSOI2008] 最大数maxnumber
    BZOJ1050 [HAOI2006] 旅行comf
    BZOJ2761 [JLOI2011] 不重复数字
  • 原文地址:https://www.cnblogs.com/rock_chen/p/1408257.html
Copyright © 2011-2022 走看看