Ejemplo de Distribucion Del Lienzo WPF con c#

2
< Window x : Class ="Ejercicio1.MainWindow" xmlns ="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns : x ="http://schemas.microsoft.com/winfx/2006/xaml" Title ="MainWindow" SizeToContent ="WidthAndHeight"> < DockPanel Width ="Auto" Height ="Auto" LastChildFill ="true"> < Menu Width ="Auto" Height ="20" Background ="Azure" DockPanel.Dock ="Top"> < MenuItem Header ="File"> < MenuItem Header ="Save"/> < MenuItem Header ="Exit"/> </ MenuItem > < MenuItem Header ="Help"> < MenuItem Header ="About"/> </ MenuItem > </ Menu > < StackPanel Width ="Auto" Height ="35" Background ="Aquamarine" Orientation ="Horizontal" DockPanel.Dock ="Bottom"> < Label Width ="135" Height ="23" Content ="Status de la barra de Mensajes" FontFamily ="Arial" FontSize ="10"/> </ StackPanel > < StackPanel Width ="136" Height ="Auto" Background ="White"> < Button Margin ="5,5,5,5" Width ="Auto" Height ="26" Content ="Boton 1"/> < Button Margin ="5,5,5,5" Width ="Auto" Height ="26" Content ="Boton 2"/> < Button Margin ="5,5,5,5" Width ="Auto" Height ="26" Content ="Boton 3"/> </ StackPanel > < Grid Width ="Auto" Height ="Auto" Background ="AliceBlue"> < Grid.ColumnDefinitions > < ColumnDefinition Width ="*"/> < ColumnDefinition Width ="*"/> </ Grid.ColumnDefinitions > < Grid.RowDefinitions > < RowDefinition Height ="*"/> < RowDefinition Height ="*"/> </ Grid.RowDefinitions > < Rectangle Fill ="Aqua" Margin ="10,10,10,10" Grid.Row ="0" Grid.Column ="0"/> < Rectangle Fill ="Pink" Margin ="10,10,10,10" Grid.Row ="0" Grid.Column ="1"/> < Rectangle Fill ="AntiqueWhite" Margin ="10,10,10,10" Grid.Row ="1" Grid.Column ="0"/> < Rectangle Fill ="DarkBlue" Margin ="10,10,10,10" Grid.Row ="1" Grid.Column ="1"/> </ Grid >

description

Ejemplo de distribución del lienzo WPF c#

Transcript of Ejemplo de Distribucion Del Lienzo WPF con c#

Page 1: Ejemplo de Distribucion Del Lienzo WPF  con c#

<Window x:Class="Ejercicio1.MainWindow" xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" Title="MainWindow" SizeToContent="WidthAndHeight"> <DockPanel Width="Auto" Height="Auto" LastChildFill="true"> <Menu Width="Auto" Height="20" Background="Azure" DockPanel.Dock="Top"> <MenuItem Header="File"> <MenuItem Header="Save"/> <MenuItem Header="Exit"/> </MenuItem> <MenuItem Header="Help"> <MenuItem Header="About"/> </MenuItem> </Menu> <StackPanel Width="Auto" Height="35" Background="Aquamarine" Orientation="Horizontal" DockPanel.Dock="Bottom"> <Label Width="135" Height="23" Content="Status de la barra de Mensajes" FontFamily="Arial" FontSize="10"/> </StackPanel> <StackPanel Width="136" Height="Auto" Background="White"> <Button Margin="5,5,5,5" Width="Auto" Height="26" Content="Boton 1"/> <Button Margin="5,5,5,5" Width="Auto" Height="26" Content="Boton 2"/> <Button Margin="5,5,5,5" Width="Auto" Height="26" Content="Boton 3"/> </StackPanel> <Grid Width="Auto" Height="Auto" Background="AliceBlue"> <Grid.ColumnDefinitions> <ColumnDefinition Width="*"/> <ColumnDefinition Width="*"/> </Grid.ColumnDefinitions> <Grid.RowDefinitions> <RowDefinition Height="*"/> <RowDefinition Height="*"/> </Grid.RowDefinitions> <Rectangle Fill="Aqua" Margin="10,10,10,10" Grid.Row="0" Grid.Column="0"/> <Rectangle Fill="Pink" Margin="10,10,10,10" Grid.Row="0" Grid.Column="1"/> <Rectangle Fill="AntiqueWhite" Margin="10,10,10,10" Grid.Row="1" Grid.Column="0"/> <Rectangle Fill="DarkBlue" Margin="10,10,10,10" Grid.Row="1" Grid.Column="1"/> </Grid> </DockPanel> </Window>